drizzle-team / drizzle-team/drizzle-orm
Add user input escaping function to `like/ilike/notLike/notIlike`
Open
db/mysql
db/postgres
db/sqlite
enhancement
qb/crud
- Dominant language
- TypeScript
- Stars
- 35.8k
- Forks
- 1.6k
- Avg merge
- 2d 7h
- Merged PRs (30d)
- 4
Description
>If the user searches for 100%, the % will be treated as a wildcard character rather than a character to be searched for
```ts
like(post.body, '%' + like.escape(userInput) + '%')
```
Based on Discord convo: https://discord.com/channels/1043890932593987624/1095907575033253971
Contributor guide
Assessment
This issue has not been assessed yet.