Marco Pivetta
1a0bb82e1d
Merge pull request #6392 from Jean85/pr_1441_rebased
...
Correct DQL `INSTANCE OF` to filter all possible child classes
2017-08-18 21:35:54 +02:00
Alessandro Lai
19bc4991ae
Add more CS fixes
2017-08-18 12:35:51 +02:00
Alessandro Lai
d4db126bb0
Remove code duplication of the getAllDiscriminators method
2017-08-18 10:17:52 +02:00
Marco Pivetta
9ad91ddc1c
#6464 #6475 using PHP 7.1 void
and string
return hints where available
2017-08-11 21:45:23 +02:00
Stefan Siegl
025ed1147b
#6464 code review updates
2017-08-11 21:36:33 +02:00
Stefan Siegl
99fdbf550d
generate nested join sql for CTIs, closes #6464
2017-08-11 21:36:33 +02:00
Sergio Santoro
e91dcf8fb4
Fix discriminator resolution when using parameters
2017-06-24 13:35:44 +02:00
Alessandro Lai
d2f7514248
Put all tests classes in a single namespace
2017-06-24 10:58:18 +02:00
Alessandro Lai
167dfde00f
Apply additional fixes to the SqlWalker to fix tests
2017-06-24 10:58:18 +02:00
Alessandro Lai
5181eae8d6
Refactor a bit the SqlWalker modifications
2017-06-24 10:58:18 +02:00
Alessandro Lai
0e88f1b654
Split SqlWalker::walkInstanceOfExpression method
2017-06-24 10:58:18 +02:00
Sergio Santoro
7d98135084
[QUERY] "INSTANCE OF" now behaves correctly with subclasses
...
There was a bug in the "INSTANCE OF" operator as described in
https://groups.google.com/forum/#!topic/doctrine-user/B8raq8CNMgg
"INSTANCE OF" was not taking into account subclasses.
It was merely translating the class to its discriminator.
This is not correct since the class can have subtypes and those
are, indeed, still instance of the superclass.
Also, classes may not have a discriminator (e.g. abstract classes).
This commit also provides useful tests to avoid regression.
2017-06-24 10:58:18 +02:00
Marco Pivetta
b21cb3e2a0
#6325 adding IDE hints, type hints, replacing double quotes with single quotes
2017-06-21 08:16:24 +02:00
Tomasz Darmetko
633a442046
Add path expresion to QueryException::associationPathInverseSideNotSupported()
2017-06-21 08:12:04 +02:00
Mathew Davies
3e3751cfd9
Remove aggregate function conditional in SqlWalker.
2017-06-20 07:27:27 +02:00
Mathew Davies
866418e40f
No longer treat aggregate functions as a special case.
2017-06-20 07:27:24 +02:00
Artem Stepin
43009682a4
minor code work:
...
- method calls with incorrect case
- removed unused imports
- typos and some other minor code smells
- documentation update (wrong return types etc. )
2017-06-08 22:04:07 +02:00
Luís Cobucci
0aef63b350
Fix quoting also when using inheritance
2017-04-30 19:36:41 +02:00
lemartin
7c6c5d87c8
Fix quoting issues related to ticket #6402
...
Apply quoting strategy to foreign key columns of one-to-one relation so
that correct select statements are generated. And use unquoted column
names in result mapping instead of quoted ones, as consumers (namely
IdentifierFlattener) expect unquoted column names.
2017-04-30 13:51:49 +02:00
Marco Pivetta
09cbb9ff48
Merge pull request #5600 from billschaller/remove-dead-code-walk-case-expression
...
Remove dead code SQLWalker::walkCaseExpression
2017-01-15 23:52:38 +01:00
Luís Cobucci
234989d069
Use short-array syntax on "lib" directory
2016-12-08 00:31:12 +01:00
ReenExe
12465e08ad
agree with scrutinizer
2016-11-26 06:40:32 +01:00
Marco Pivetta
24da9061b9
#5987 inlined check for boolean 'true'
literal
2016-11-26 05:22:43 +01:00
Javier Spagnoletti
e2b198112e
[minor] Add missing type hints, add strictness for some checks, remove some useless calls
2016-11-26 05:18:46 +01:00
Bill Schaller
744c308337
Remove dead code SQLWalker::walkCaseExpression
2016-01-08 13:58:02 -05:00
Bill Schaller
55d4f515af
Fix issue were identifier operands in /,* arithmetic terms were not checked to see if they're query components
2016-01-08 12:53:05 -05:00
Jeroen Thora
6dcb97a20e
Fixed many small phpcs issues
2015-12-11 20:30:41 +01:00
Matthias Pigulla
b7bd42638d
Fix for DDC-3697 and DDC-3701
...
Also fix Lexer::match() so it does not accept T_WHERE when T_WITH is supposed to be matched. (DDC-3701)
2015-11-09 03:19:11 +00:00
Guilherme Blanco
843966ac50
General fixes across CS, type resolving, test fixes, etc
2015-11-07 03:55:05 +00:00
Andy Cook
26c295b06b
Added non-functional tests for row number over function subselect expression fix; syntax fixes.
2015-07-17 13:24:19 +01:00
Andy Cook
61488d955e
Fixed issue when paginator orders by a subselect expression on platforms supporting ROW_NUMBER OVER() function.
2015-07-16 11:20:22 +01:00
Benjamin Morel
517cb7e2a2
Honor convertToDatabaseValueSQL() in DQL query parameters
2015-03-18 00:24:41 +01:00
James Murray
d9cbe1a8b7
removed unnecessary fieldIdentificationVariable property check
2014-12-19 14:10:47 -05:00
James Murray
85eac7200d
Adding the ability to alias new object expressions
2014-10-28 17:34:57 -04:00
Marco Pivetta
b989175754
#615 - Removing unused assignment
2014-10-19 17:24:07 +02:00
Marco Pivetta
a4e9c235f8
#615 - assignment alignment
2014-10-19 17:08:33 +02:00
Mike Meier
fb5f76f025
rewrite tablePrefixAlias
2014-10-19 17:05:34 +02:00
Mike Meier
ebc996c820
Update SqlWalker.php
...
Always be sure that only a-z characters are used for table alias, otherwise use generic "t" for "table"
2014-10-19 17:05:34 +02:00
Marco Pivetta
b80149344d
Merge pull request #1073 from kamazee/add_passing_type_to_rsm_in_sql_walker
...
Add missing type mapping
2014-07-14 10:51:13 +02:00
Alexander Kurilo
38fcc66c16
Add missing type mapping
...
Fixes DDC-3192
Refs DDC-2494
This is essentially a fix from DDC-2494 applied to SQLWalker.
The issue: type was not converted to PHP value when the result is fetched by
executing DQL query rather than using entity manager's findX(). Similar issue
for BasicEntityPersister (which is used when em's findX is executed) was fixed
in DDC-2494, but SQLWalker made the issue valid for any custom query.
2014-07-14 11:22:08 +03:00
Daniel Sippel
45358bf5d0
possible fix for DDC-2021
2014-07-09 16:39:44 +02:00
Guilherme Blanco
6a8ee87268
Made DQL and EBNF in sync.
2014-04-20 20:27:57 +00:00
Guilherme Blanco
a3f95d919b
DDC-3075 Added support for subqueries in NEW operator.
2014-04-20 14:40:51 +00:00
Benjamin Eberlei
2aea3036b6
[DDC-3018] Fix string literals in new operator.
2014-03-23 15:16:09 +01:00
Guilherme Blanco
0dbd742588
Merge pull request #886 from Strate/bugfix/join-with-condition-placement-fix
...
[DDC-1256] Fix applying ON/WITH conditions to first join in Class Table Inheritance
2014-02-17 12:12:05 -05:00
Strate
324f200f1b
Merge branch 'master' into bugfix/join-with-condition-placement-fix
2014-02-10 08:22:11 +04:00
Benjamin Morel
08f6291350
Cleaned up further unused imports.
2014-02-09 23:45:22 +00:00
Steve Müller
a6c8ab8a5f
make lock mode usage consistent
2014-02-05 15:13:53 +01:00
Strate
04e6061584
Added an exception when invalid case.
...
Fixes after code review.
2014-01-20 20:06:53 +04:00
Strate
41ec5fd56d
Fix applying ON/WITH conditions to first join in Class Table Inheritance
...
Now we build nested joins for CTI when using ON/WITH clause.
2014-01-19 20:56:24 +04:00