drizzle-team / drizzle-team/drizzle-orm-docs
Update the guide about upsert-operations to document the `targetWhere` property of `onConflictDoUpdate()`
- Dominant language
- MDX
- Stars
- 241
- Forks
- 401
- Avg merge
- 5h 44m
- Merged PRs (30d)
- 1
Description
In the section about PostgreSQL and SQLite of https://orm.drizzle.team/docs/guides/upsert, one example passes the `setWhere` property to `onConflictDoUpdate()`. However, the guide doesn't mention the `targetWhere` property, nor describe when it is useful. It would also be good to describe the difference between the two properties to explain when to use which one of them.
## Suggested improvements:
- Add an example showing how to use `targetWhere`, and describing how it works. E.g. show the generated SQL statement.
- Describe the difference between `setWhere` and `targetWhere`, and when to use which one of them.
This might be useful to describe how the upsert operation works in SQLite, and the difference between `setWhere` and `targetWhere`: https://www.sqlite.org/lang_upsert.html
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.