Igor Tandetnik wrote: > On 8/6/2013 5:28 PM, Baruch Burstein wrote: >> create table tests (id INTEGER PRIMARY KEY, name TEXT UNIQUE); >> insert into tests values ('test 1'); >> >> Error: table tests has 2 columns but 1 values were supplied >> >> Since the id column is an alias for the rowid, shouldn't I be able to not >> supply it? > > Yes you should be. You do that by providing an explicit list of columns that > omits it: > > insert into tests(name) values ('test 1');
Or by giving the rowid value as NULL: INSERT INTO tests VALUES(NULL, 'test 1'); Regards, Clemens _______________________________________________ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users