Re: [sqlite] How to handle dual-field Primary Key - only one is Autoincrement

2007-01-12 Thread Ken
Besides the trigger issue with sqlite. I think you have a design issue with your tables. You are using a composite key. Why not have a master table of customer I'ds that you maintain, whith only the customer_id as the PK and autoincrement. The the table you refer to would then be a child of

Re: [sqlite] How to handle dual-field Primary Key - only one is Autoincrement

2007-01-11 Thread Dan Kennedy
On Thu, 2007-01-11 at 21:47 -0500, Dan Cooperstock wrote: > I have a slightly unusual situation in my database design. Several of my > tables have primary keys composed of two integer fields, such as customerid > and year. The customerid should be an Autoincrement field, in the sense that > when a

[sqlite] How to handle dual-field Primary Key - only one is Autoincrement

2007-01-11 Thread Dan Cooperstock
I have a slightly unusual situation in my database design. Several of my tables have primary keys composed of two integer fields, such as customerid and year. The customerid should be an Autoincrement field, in the sense that when a new customer is added, it should get an auto-generated customerid