[PR #998] [CLOSED] DDC-3065 null value in in criteria support #9016

Closed
opened 2026-01-22 16:02:48 +01:00 by admin · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/doctrine/orm/pull/998
Author: @Ocramius
Created: 4/3/2014
Status: Closed

Base: masterHead: hotfix/DDC-3056-null-value-in-in-criteria-support


📝 Commits (5)

  • 2cec272 DDC-3056 - failing test - IN()-alike criteria should support NULL search values
  • a9a5062 DDC-3056 - hardening test - should support multiple values in IN(), also NULL ones
  • 9780a97 DDC-3056 - splitting tests and checking multiple values support
  • 978738d DDC-3056 - persister tests for criteria containing NULL values in IN() conditions
  • ee7e25c DDC-3056 - applying hotfix that allows NULL in IN() criteria

📊 Changes

3 files changed (+122 additions, -1 deletions)

View changed files

📝 lib/Doctrine/ORM/Persisters/BasicEntityPersister.php (+7 -1)
📝 tests/Doctrine/Tests/ORM/Functional/EntityRepositoryTest.php (+84 -0)
📝 tests/Doctrine/Tests/ORM/Persisters/BasicEntityPersisterTypeValueSqlTest.php (+31 -0)

📄 Description

See DDC-3065 (http://www.doctrine-project.org/jira/browse/DDC-3065)

This MAY be a breakage, since the following API now works as expected:

$repository->findBy(['fieldName' => [null]]);
$repository->findBy(['fieldName' => [123, null]]);

Where before, null was just ignored


🔄 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/998 **Author:** [@Ocramius](https://github.com/Ocramius) **Created:** 4/3/2014 **Status:** ❌ Closed **Base:** `master` ← **Head:** `hotfix/DDC-3056-null-value-in-in-criteria-support` --- ### 📝 Commits (5) - [`2cec272`](https://github.com/doctrine/orm/commit/2cec2726c00e0f641562c5e918426e5888f156f4) DDC-3056 - failing test - IN()-alike criteria should support NULL search values - [`a9a5062`](https://github.com/doctrine/orm/commit/a9a50625a5629ab39fa04911a11deaefec032246) DDC-3056 - hardening test - should support multiple values in IN(), also NULL ones - [`9780a97`](https://github.com/doctrine/orm/commit/9780a97e6552a368625d48fbeffc2bd7956b2623) DDC-3056 - splitting tests and checking multiple values support - [`978738d`](https://github.com/doctrine/orm/commit/978738d2713cf023335df2ea62bbe064c361360d) DDC-3056 - persister tests for criteria containing `NULL` values in `IN()` conditions - [`ee7e25c`](https://github.com/doctrine/orm/commit/ee7e25c4f64c81abd18ecea9fa34c2a9fc437b6f) DDC-3056 - applying hotfix that allows `NULL` in `IN()` criteria ### 📊 Changes **3 files changed** (+122 additions, -1 deletions) <details> <summary>View changed files</summary> 📝 `lib/Doctrine/ORM/Persisters/BasicEntityPersister.php` (+7 -1) 📝 `tests/Doctrine/Tests/ORM/Functional/EntityRepositoryTest.php` (+84 -0) 📝 `tests/Doctrine/Tests/ORM/Persisters/BasicEntityPersisterTypeValueSqlTest.php` (+31 -0) </details> ### 📄 Description See DDC-3065 (http://www.doctrine-project.org/jira/browse/DDC-3065) This _MAY_ be a breakage, since the following API now works as expected: ``` php $repository->findBy(['fieldName' => [null]]); $repository->findBy(['fieldName' => [123, null]]); ``` Where before, `null` was just ignored --- <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:02:48 +01:00
admin closed this issue 2026-01-22 16:02:48 +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#9016