Re: [sqlite] primary key on two columns of an associative table

2011-03-28 Thread BareFeetWare
On 29/03/2011, at 12:59 AM, Sam Carleton wrote: > The system calls for an associative table, a table with two foriegn > keys to two other tables, allowing for a many to many relationship. > Is there any way to make the primary key be both the columns? Yes, you can define a primary key on two colu

Re: [sqlite] primary key on two columns of an associative table

2011-03-28 Thread Jay A. Kreibich
On Mon, Mar 28, 2011 at 09:59:59AM -0400, Sam Carleton scratched on the wall: > The system calls for an associative table, a table with two foriegn > keys to two other tables, allowing for a many to many relationship. > Is there any way to make the primary key be both the columns? > > CREATE TABLE

[sqlite] primary key on two columns of an associative table

2011-03-28 Thread Sam Carleton
The system calls for an associative table, a table with two foriegn keys to two other tables, allowing for a many to many relationship. Is there any way to make the primary key be both the columns? CREATE TABLE Invoice_Item_Favorite( Invoice_Item_Id INTEGER, FavoriteId INTEGER,