2011/12/25 get bridges <softcrea...@163.com>: > create table IF NOT EXISTS Unions > ( > Id integer primary key autoincrement, > UName nvarchar(500) unique, > Filter bit not null default 0 > ); > > replace into Unions(UName,Filter) values('a','True')--Source Id is 1 > replace into Unions(UName,Filter) values('a','False')//Changed Id is 2 > why primary key can changed?Id changed is 2,is bug?
REPLACE is an alias of INSERT OR REPLACE. http://www.sqlite.org/lang_replace.html The record is inserted, then duplicity is deleted. If you want to update record, use the UPDATE. -- Kit _______________________________________________ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users