Skip to content

Merge 2.20.x up into 3.5.x#12150

Merged
greg0ire merged 3 commits intodoctrine:3.5.xfrom
greg0ire:3.5.x
Aug 28, 2025
Merged

Merge 2.20.x up into 3.5.x#12150
greg0ire merged 3 commits intodoctrine:3.5.xfrom
greg0ire:3.5.x

Conversation

@greg0ire
Copy link
Copy Markdown
Member

No description provided.

mpdude and others added 2 commits March 30, 2025 22:44
… on to-many-collections

This fixes that using a `Criteria` with an `IN` or `NIN` expression on a to-many collection currently leads to an SQL error (doctrine#6173). The `ManyToMany` persister needs to know about the slightly different SQL syntax for `[NOT] IN ()`.

In the case of `[NOT] IN` expressions, the value will be an array, which also required me to change (I guess "fix") the parameter type handling. I have pulled the necessary code from the `BasicEntityPersister` and placed it as static helper methods in `PersisterHelper`.

This is somewhat inspired by doctrine#11516, which aims at fixing doctrine#11481: By re-using the parameter type handling code, it also fixes using backed enums in `EQ`, `IN` and `NIN` expressions within `Criteria` when `matching()` on one-to-many and many-to-many collections.
…ression

Fix `IN`/`NOT IN` expression handling and support enums when matching on to-many-collections
@greg0ire greg0ire force-pushed the 3.5.x branch 3 times, most recently from 44a7598 to 6ce0e17 Compare August 26, 2025 21:57
@greg0ire greg0ire merged commit 48434f4 into doctrine:3.5.x Aug 28, 2025
85 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants