[PR #791] [MERGED] Implemented "contains" operator for Criteria expressions #8712

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

📋 Pull Request Information

Original PR: https://github.com/doctrine/orm/pull/791
Author: @mnapoli
Created: 9/16/2013
Status: Merged
Merged: 10/11/2013
Merged by: @guilhermeblanco

Base: masterHead: CriteriaContains


📝 Commits (1)

  • 6f538c5 Implemented "contains" operator for Criteria expressions

📊 Changes

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

View changed files

📝 lib/Doctrine/ORM/Query/QueryExpressionVisitor.php (+5 -0)
📝 tests/Doctrine/Tests/ORM/Query/QueryExpressionVisitorTest.php (+2 -0)

📄 Description

Criteria expressions support the contains operator, and it is implemented for the ArrayCollection. However, it wasn't implemented in the QueryExpressionVisitor, the ORM implementation.

This is the implementation and the test.

The only thing I'm wondering: is the % wildcard valid for all supported RDBMS for the LIKE operator? After a quick search, it seems like so, but you guys probably know for sure.

FYI it seems that someone created an issue for this, but it was closed: DDC-2394


🔄 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/791 **Author:** [@mnapoli](https://github.com/mnapoli) **Created:** 9/16/2013 **Status:** ✅ Merged **Merged:** 10/11/2013 **Merged by:** [@guilhermeblanco](https://github.com/guilhermeblanco) **Base:** `master` ← **Head:** `CriteriaContains` --- ### 📝 Commits (1) - [`6f538c5`](https://github.com/doctrine/orm/commit/6f538c509ced72dfe538f4ab2200f67121067d55) Implemented "contains" operator for Criteria expressions ### 📊 Changes **2 files changed** (+7 additions, -0 deletions) <details> <summary>View changed files</summary> 📝 `lib/Doctrine/ORM/Query/QueryExpressionVisitor.php` (+5 -0) 📝 `tests/Doctrine/Tests/ORM/Query/QueryExpressionVisitorTest.php` (+2 -0) </details> ### 📄 Description Criteria expressions support the contains operator, and it is implemented for the ArrayCollection. However, it wasn't implemented in the QueryExpressionVisitor, the ORM implementation. This is the implementation and the test. The only thing I'm wondering: is the `%` wildcard valid for all supported RDBMS for the `LIKE` operator? After a quick search, it seems like so, but you guys probably know for sure. FYI it seems that someone created an issue for this, but it was closed: [DDC-2394](http://www.doctrine-project.org/jira/browse/DDC-2394) --- <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:12 +01:00
admin closed this issue 2026-01-22 16:01:13 +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#8712