In SQLITE, how do you create a new table into its own file? I am trying to do key value pairing, where performance is the top priority. I understand that the smaller a sqlite file is, the better the read and write speeds are, and so I am going to create about 64 files, having every explicit key-value combination.
Hence I would like to create a command that will create a new table inside its own file. How do I do this?
Thanks.
If you're trying to store key-value pairs of data you should use a key-value store database instead of SQLite, since SQLite is meant to store relational data. Where is your database going to live?...mobile device or dedicated server?
If you do stick to SQLite though, file size is not much of a factor in terms of read and write speeds. Rather you're probably thinking of concurrency issues, especially with concurrent writes to the database. In that case, you can do things like enabling the WAL and possibly creating a separate database for any groups of tables you would need to heavily concurrently write to, since concurrency issues mostly occur within the same database. Also ensure you index your tables appropriately, which will likely just be the key of your key-value pairs.
Also switching to an appropriate key-value data store would likely help you with any concurrency issues as well.