Question

I have a list of about 2000 objects (in this case, Teamspeak channels) and I would like to record (to disk) whether they are empty or not, in order to determine which ones are being used.

I'm having trouble solving this since I'm doing 2000 inserts every 10 seconds, and that's thrashing my disk. However I'm sure there must be a better way to do this! I'm just interested in getting a list of unused channels (say, channels that were empty for 2 weeks) to delete later.

Should I be using a relational database? Is there a better way of acomplishing what I want to do?

Était-ce utile?

La solution

If you want SQLite to handle that many records, you have to batch them in transactions. See http://sqlite.org/faq.html#q19

But I suspect you don't need to record that much data, if all you want is the information about which channels are empty.

Licencié sous: CC-BY-SA avec attribution
Non affilié à StackOverflow
scroll top