Home » U++ Library support » U++ SQL » Fields
Re: Fields [message #4164 is a reply to message #4163] |
Wed, 26 July 2006 10:38   |
|
aroman wrote on Wed, 26 July 2006 03:54 | I didn't actually read all the way through your post, I noticed this:
sql * Insert(TABLE)(C0, "a")(C1, 1)(C3, 2)
if(duplicate())
sql * Update(TABLE)(C0, "a")(C1, 1)(C3, 2)
In sqlite, at least, you can use "REPLACE" to insert or update. According the the sqlite documentation, it's also in mysql:
http://www.sqlite.org/lang_replace.html
Perhaps that should be added to the sql interface.
=)
- Augusto
|
It is not only about sqlite3 MS SQL Server (which I use in my projecte doesn't have such a possibility (or I missed sth..)
But for example in MySql there is Insert into... on duplicate key update or sth similar.
|
|
|
Goto Forum:
Current Time: Mon Jun 23 12:04:26 CEST 2025
Total time taken to generate the page: 0.04120 seconds
|