Hi all,
I have emp sqlite table:
create table if not exists emp(id integer primary key autoincrement,
col1 text, col2 text, unique (col1, col2));
here, col1 and col2 should be unique. I tried to insert 10000000 records
with unique(col1, col2). It's very slow. So, I choosed id as primary key
(surrogate key) and without unique key.
create table if not exists emp(id integer primary key autoincrement, col1
text, col2 text);
I want to insert a record if not exists. How?
I tried with insert or replace. Duplicates are occuring. While inserting, I
dont have primary key in my hand.
Note: id is foreign key in other 4 tables.
Thanks in advance,
Durga.
_______________________________________________
sqlite-users mailing list
[email protected]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users