On Thu, Nov 27, 2008 at 08:12:02AM +0000, Simon Bulman wrote:
> Morning,
> 
> Table 1
> 
> BIGINT (index),  VARCHAR(30), VARCHAR(10)
> 
>  
> 
> Table 2
> 
> BIGINT (index), FLOAT


For the second table, the index will contain the BIGINT value and the table
rowid, which is almost as big as the actual row, so use of a separate index
will literally double storage used for the second table including index.

If your BIGINT fields are just record ids, then you are better off using
an "integer primary key" for these fields, as this is used as the table
rowid, and no separate index will be required. The "integer primary key"
type is good for 64 bit ids, so should be adequate.

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

Reply via email to