[PR #819] [MERGED] Fixes a Fatal Error when using a subexpression in parenthesis #8754

Open
opened 2026-01-22 16:01:34 +01:00 by admin · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/doctrine/orm/pull/819
Author: @vbourdeix
Created: 10/14/2013
Status: Merged
Merged: 10/14/2013
Merged by: @guilhermeblanco

Base: masterHead: master


📝 Commits (1)

  • 5506d7a Fixes a Fatal Error when using a subexpression in parenthesis

📊 Changes

2 files changed (+11 additions, -0 deletions)

View changed files

📝 lib/Doctrine/ORM/Query/SqlWalker.php (+4 -0)
📝 tests/Doctrine/Tests/ORM/Query/SelectSqlGenerationTest.php (+7 -0)

📄 Description

When some dql contains a subselect with expression in parenthesis, the
expression of the $simpleSelectExpression parameter given to
walkSimpleSelectExpression is an instance of AST\ParenthesisExpression.
Before this commit, this case defaulted to
$this->walkEntityIdentificationVariable($expr) where $expr is supposed
to be a string. A fatal error was then yielded.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/doctrine/orm/pull/819 **Author:** [@vbourdeix](https://github.com/vbourdeix) **Created:** 10/14/2013 **Status:** ✅ Merged **Merged:** 10/14/2013 **Merged by:** [@guilhermeblanco](https://github.com/guilhermeblanco) **Base:** `master` ← **Head:** `master` --- ### 📝 Commits (1) - [`5506d7a`](https://github.com/doctrine/orm/commit/5506d7adce0cc75c38b42280b2bf524046d5e56e) Fixes a Fatal Error when using a subexpression in parenthesis ### 📊 Changes **2 files changed** (+11 additions, -0 deletions) <details> <summary>View changed files</summary> 📝 `lib/Doctrine/ORM/Query/SqlWalker.php` (+4 -0) 📝 `tests/Doctrine/Tests/ORM/Query/SelectSqlGenerationTest.php` (+7 -0) </details> ### 📄 Description When some dql contains a subselect with expression in parenthesis, the expression of the $simpleSelectExpression parameter given to walkSimpleSelectExpression is an instance of AST\ParenthesisExpression. Before this commit, this case defaulted to $this->walkEntityIdentificationVariable($expr) where $expr is supposed to be a string. A fatal error was then yielded. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
admin added the pull-request label 2026-01-22 16:01:34 +01:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: doctrine/archived-orm#8754