[DDC-1815] using aliases from select clause in having clause does not work Created: 08/May/12  Updated: 06/Oct/12  Resolved: 06/Oct/12

Status: Resolved
Project: Doctrine 2 - ORM
Component/s: DQL
Affects Version/s: 2.2.2
Fix Version/s: None
Security Level: All

Type: Bug Priority: Major
Reporter: Bart van den Burg Assignee: Benjamin Eberlei
Resolution: Cannot Reproduce Votes: 0
Labels: None


I have the following DQL:

SELECT e, count(s) AS shiftsTooLate FROM RAI\ShifterBundle\Entity\Worker e INNER JOIN e.person person LEFT JOIN e.shifts s 
WITH s.reasonTooLate IS NOT NULL LEFT JOIN e.person a96582 LEFT JOIN e.person a31040 LEFT JOIN e.person a49970 
LEFT JOIN e.pools a30107 LEFT JOIN e.person a12776 LEFT JOIN a12776.qualifications a78193 LEFT JOIN e.person a38925 
WHERE (e.blacklist = :f0) AND (e.haccpInstruction = :f1) AND (e.introductoryMaterial = :f2) GROUP BY e.id HAVING (shiftsTooLate = :f3) 

When I try to execute this query, I get an undefined index error:


Comment by Benjamin Eberlei [ 27/May/12 ]

can you execute the query without being wrapped into KNP Paginator?

Comment by Benjamin Eberlei [ 06/Oct/12 ]

No feedback given and executed in context of knp paginator, which probably is the source of the error.

Generated at Tue Oct 13 19:17:31 EDT 2015 using JIRA 6.4.10#64025-sha1:5b8b74079161cd76a20ab66dda52747ee6701bd6.