Dear All,

According to the documentation, and as far as I can see, also in
reality, INSERT OR REPLACE
will remove existing columns which conflict regarding a unique key.

Quite contrary to my initial foolish belief, it doesn't work at all
like a hypothetical
INSERT OR UPDATE, which in case of multiple conflicting rows would have to fail
anyway and in case of a single conflicting row would update *that*
*row* -- i.e. leaving
the rowid and all columns not specified in the statement intact.

What would be efficient and correct SQL to get the INSERT OR UPDATE
behaviour? Am I right
in assuming, that it will always suffer a performance penalty, either
in the INSERT or in the
UPDATE case, depending on the SQL used?

Regards,
Peter
_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to