Shane Harrelson wrote:
We've declared an INTEGER column as the PRIMARY KEY on all tables as
below:
CREATE TABLE Strings ( StringId INTEGER PRIMARY KEY, Value VARCHAR(30)
UNIQUE )
It is my understanding that this makes it an alias to the "internal"
ROWID used by SQLite. On insertions we don't specifiy the key,
allowing SQLite to generate this for us
(http://www.sqlite.org/faq.html#q1).
Would there be any benefit to "pre-sorting" in this scenario?
Shane,
By leaving the integer primary key columns null you are already letting
sqlite append the new records onto the ends of the tables. There might
be a small speedup by pre-sorting the strings to be inserted within a
transaction so that they are added to the unique index in order, but
that may be offset by cost of doing the sorts.
HTH
Dennis Cote
-----------------------------------------------------------------------------
To unsubscribe, send email to [EMAIL PROTECTED]
-----------------------------------------------------------------------------