Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.
Sign upProvide an easy way to "insert or replace" or conditionally insert #296
Comments
This comment has been minimized.
|
We don't have any support for upsert at the moment, but this is something I'd like to add in the future. See #196. I'm going to bump this to the 0.7 milestone, as SQLite in particular should be extremely easy to support for this case. I'll see if I can add it today. |
sgrif
closed this
Apr 22, 2016
This comment has been minimized.
llogiq
commented
Apr 22, 2016
|
I see. No hurry, I'll need some time to finish the rest anyway. Thank you for the quick response! |
This comment has been minimized.
|
No problem. SQLite also supports specifying that upsert should occur in the table's schema. Worst case, you could always specify the |
llogiq commentedApr 22, 2016
I'm thinking about using diesel in a project, where I get a stream of data that may contain duplicates, and I want only distinct data in my database, so an insert or replace statement would be quite helpful. I should note that I plan to use the sqlite backend. What are my options?