On 14 Nov 2013, at 2:16am, Igor Korot <ikoro...@gmail.com> wrote:

> Simon,
> 
> On Wed, Nov 13, 2013 at 5:53 PM, Simon Slavin <slav...@bigfraud.org> wrote:
>> 
>> On 14 Nov 2013, at 12:53am, Igor Korot <ikoro...@gmail.com> wrote:
>> 
>>> Can I use the same field as both primary key and foreign key?
>> 
>> Yes.  Good idea, in fact.
> 
> Is it documented anywhere - either on SQLite documentation or in a standard?

Not that I know of.

A foreign key involves two fields in different tables.  I've done one way 
times.  In fact almost all foreign keys relate to a primary key.  The other way 
I don't think I've used but I see no reason why it shouldn't work.

Simon.
_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to