RB Smissaert wrote:
Is it right that this won't affect the speed of any subsequent inserts or
deletes?
Well inserts will be done in id order. If you have predefined ids
assigned by some outside source and specify them when you insert into
sqlite, it will have to insert at random location in the btree. This
will take longer than always appending at the end of the btree. If you
let sqlite assign the ids, or the ids are in order, then this is not an
issue. If you are always going to create the external index afterwards
anyway, it will also probably not make much difference (you would have
to test it each way).
About the single quotes etc:
This is VB code, so I can't do:
Create table "table1"("ID" INTEGER PRIMARY KEY)
I can do:
Create table table1(ID INTEGER PRIMARY KEY)
As the table and the columns are often variables it will be something like:
strTable = "table1"
strColumn = "ID"
strSQL = "create " & strTable & "(" & strColumn & " INTEGER PRIMARY KEY)"
VB and SQL both use the same technique of escaping quotes embedded in
strings using a pair of quotes back to back.
In VB
print "Test ""quoted"" strings."
will output
Test "quoted" strings.
You can do the same with the strings you are building to send to SQLite.
Using the following VB statement
strSQL = "create """ & strTable & """(""" & strColumn & """ INTEGER
PRIMARY KEY)"
will produce a strSQL that contains the string
create "table1"("ID" INTEGER PRIMARY KEY)
HTH
Dennis Cote
-----------------------------------------------------------------------------
To unsubscribe, send email to [EMAIL PROTECTED]
-----------------------------------------------------------------------------