Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.Sign up
HAVING after nested SELECT doesn't work correctly in PHQL #12548
SELECT grandParent.id, SUM(parent.total) AS total FROM Parents AS parent INNER JOIN GrandParents AS grandParent ON parent.grandParent = parent.id WHERE NOT EXISTS ( SELECT * FROM Childs AS child WHERE parent.id = child.parent ) HAVING total > 1
That causes the PHQL parser to throw an exception that "total is not a column". If I switch to:
PHP 7 with Phalcon 3.0 (master).
Thank you for contributing to this issue. As it has been 90 days since the last activity, we are automatically closing the issue. This is often because the request was already solved in some way and it just wasn't updated or it's no longer applicable. If that's not the case, please feel free to either reopen this issue or open a new one. We will be more than happy to look at it again! You can read more here: https://blog.phalconphp.com/post/github-closing-old-issues