postgres case-insensitive filtering with equals uses ILIKE #20318
Labels
bug/2-confirmed
Bug has been reproduced and confirmed.
kind/bug
A reported bug.
team/client
Issue for team Client.
tech/engines
Issue for tech Engines.
topic: insensitive
topic: security
Bug description
For Postgres, when using a filter with
equals
andmode: "insensitive"
, the query usesILIKE
.How to reproduce
Expected behavior
I'd expect this to do something like:
This makes using user input dangerous since you now have to sanitize against
%
and_
(emails can contain_
so this makes it unusable for this particular use case).Prisma information
see "how to reproduce"
Environment & setup
Prisma Version
The text was updated successfully, but these errors were encountered: