[sqlite] multiple table constraints

2018-03-07 Thread Mark Wagner
The syntax for multiple table constraints seems to specify a comma between each constraint but I noticed that no comma separator seems to be accepted as well. e.g. both are accepted CREATE TABLE foo(_id primary key, x, y, unique(x), unique(y)); CREATE TABLE foo(_id primary key, x, y, unique(x) un

Re: [sqlite] multiple table constraints

2018-03-07 Thread Richard Hipp
On 3/7/18, Mark Wagner wrote: > > e.g. both are accepted > > CREATE TABLE foo(_id primary key, x, y, unique(x), unique(y)); > CREATE TABLE foo(_id primary key, x, y, unique(x) unique(y)); > > Just curious if this is some historical artifact or if there's some > difference between the two that I'm

Re: [sqlite] multiple table constraints

2018-03-07 Thread Mark Wagner
Thanks for the detailed response. I was really confused for a few minutes this morning noticing both forms in my code. :) On Wed, Mar 7, 2018 at 9:44 AM, Richard Hipp wrote: > On 3/7/18, Mark Wagner wrote: > > > > e.g. both are accepted > > > > CREATE TABLE foo(_id primary key, x, y, unique(x

Re: [sqlite] multiple table constraints

2018-03-07 Thread David Raymond
list Subject: Re: [sqlite] multiple table constraints I would fix this parser problem, except there are literally over a trillion SQLite database files in circulation, and even if only 0.001% of those use the incorrect second form, that still means millions of database files out there that would