Sunday 15 June 2014

Quickest way to insert into SQLite using C API? -


I want to include a lot (let's say millions) as soon as possible in the database. Since I'm calling from C, I thought there might be a shortcut to do this in the API. I can not help, but I think that the string from the data is created and the string is written back, all in one call, it is least efficient.

Is there no way to insert data into SQL strings? Ready statement is the only way?

I am looking for the se-specific methods of inserting data in the most efficient way, not general database tips

Start a transaction in the code, and a committed commit will be in all inserted memory before being written to disk. (How much memory is available to you, and depending on how much data you enter it may have to be trudged) This is going to boost you to the biggest exposure you will see.

Otherwise, if one is included in the same table, to prevent the text processing overhead, after each one is inserted, then reboot the one line in one of your data at the same time. However, compared to transactions, this would be relatively minor, most of the time your inserted disk will be written in ...


No comments:

Post a Comment