On 18 Sep 2016, at 7:21am, Clemens Ladisch <clem...@ladisch.de> wrote:
> mikeegg1 wrote: >> The insert statement is a “insert or replace into…” so I don’t have to >> deal with insertion errors. However, I expected the rowid to not change >> when the row has not changed. > > The OR REPLACE clause just deletes any old row. > > If you want to update the old row, use UPDATE. (And there's no good way > to do this with a single SQL statement.) Right. If you want the same functionality as INSERT OR REPLACE then do INSERT OR IGNORE ... UPDATE ... If the existing row already exists then the new one won't be inserted, but the UPDATE will affect both new and old rows. Simon. _______________________________________________ sqlite-users mailing list sqlite-users@mailinglists.sqlite.org http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users