-
Notifications
You must be signed in to change notification settings - Fork 2.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Cannot use criteria matching with entities where the primary key is a binary ULID #8995
Comments
If I make a modification to
Then it works, but it isn't really a solution since this is Doctrine ORM code which knows nothing about the Symfony UID component. |
Well, the right fix would be to use the metadata to determine the type of the field, and bind the parameter with an explicit type instead of relying on type guessing. |
Should be moved to ORM? |
If you can do that great. I wasn't sure how the internals work and if the ORM would know about the Symfony ULID type which is non-standard. Will have a poke around some more and see if I can figure it out. |
Is this a duplicate of #8406 ? |
Yes looks like it is |
Duplicate of #8406 |
I'm trying to do an efficient join using criteria in one of my entities like:
However the query doctrine creates is:
As you can see it has just turned the ULID into a string which won't match the binary.
I feel like this maybe come from
vendor/doctrine/orm/lib/Doctrine/ORM/Persisters/Collection/ManyToManyPersister.php
Where maybe the
$params[]
being created here isn't using the binary value.Anyone know where this bug might lie who knows a bit more about how it work, I'm also not sure who is responsible, Doctrine ORM, Doctrine Bundle, Symfony Uid...
The text was updated successfully, but these errors were encountered: