0
Fork 0
mirror of https://github.com/logto-io/logto.git synced 2024-12-23 20:33:16 -05:00
logto/.changeset/chilly-bobcats-doubt.md
simeng-li 9222eb9f80
refactor(core): add on conflic ignore to the Relation insert query method (#5100)
* refactor(core): add on conflic ignore to the Relation insert query method

add on conflic ignore to the Relation insert query method

* chore: improve word

improve word

* test: add integration test

add integration test

* feat(core): update organization post api doc

update organization post api doc
2023-12-14 15:04:20 +08:00

520 B

@logto/core
patch

Set on conflict do nothing for all the RelationQueries insert operation.

  • For all the relation table entities, we want to safely insert them into the database. If the relation entity already exists, instead of throwing an error, we ignore the insert operation, especially on a batch insert. Unlike other resource data entities, user does not care if the relation entity already exists. Therefore, we want to silently ignore the insert operation if the relation entity already exists.