开发者

update or insert in sqlite3

开发者 https://www.devze.com 2023-03-12 02:16 出处:网络
Am using sqlite3 in linux machines. I need to update the values if primary key exists, el开发者_Python百科se record should be inserted. Is there any query statement for this.REPLACE you should use

Am using sqlite3 in linux machines.

I need to update the values if primary key exists, el开发者_Python百科se record should be inserted. Is there any query statement for this.


REPLACE you should use

insert or replace into t (a, b, c) values ('a', 'b', 'c');

this is an example....

0

精彩评论

暂无评论...
验证码 换一张
取 消