Skip to content

How to perform an UPSERT operation? #239

Answered by vincent-herlemont
agersant asked this question in Q&A
Discussion options

You must be logged in to vote

You are correct, there was no upsert function on the existing release of Native DB. This has been added for version 0.8.0, which will be released next week. (See code upsert).

If you want to perform an upsert with previous versions, you can check for existence using get and use insert or update depending on whether the data exists.

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by agersant
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants