I believe you may be right...can someone in-the-know confirm that the "create 
index" below is redundant?

I'm the type that likes to be explicit but perhaps that's a bad idea here.  Do 
we end up with 2 indexes thereby slowing things down on inserts?





Michael D. Black

Senior Scientist

NG Information Systems

Advanced Analytics Directorate



________________________________
From: sqlite-users-boun...@sqlite.org [sqlite-users-boun...@sqlite.org] on 
behalf of Roger Andersson [r...@telia.com]
Sent: Thursday, June 30, 2011 7:45 AM
To: sqlite-users@sqlite.org
Subject: EXT :Re: [sqlite] Defining a relationship as unique

  On 06/30/11 02:31 PM, Black, Michael (IS) wrote:
> sqlite>  create table user(userid integer primary key autoincrement,name 
> varchar, login varchar);
> sqlite>  create unique index index1 on user(userid);
Isn't userid already unique by "userid integer primary key"?
/Roger
_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to