What is the storage limit for Sqlite?

Asked

Viewed 6,034 times

21

A new demand for the application of the company where I work, I need to store more than 100k of records in different tables, I’m worried if the Sqlite will withstand such demand, my question is:

  • Sqlite has storage limit?
  • The type of data influence the storage limit?

1 answer

26


The line limit is 2 raised to 64, that is, there is no practical limit.

There is the 128TB limit on the total size of bytes database, which in practice is difficult to achieve. Remembering that Sqlite works with every database in a single file.

Of course this limit depends on Sqlite configuration, whether in the compilation of it, or by some PRAGMA, then it is possible to change.

Almost all database boundaries can be set and relevant ones are available on documentation.

The size of the pages can negatively or positively affect the performance of the database. In general the best results are obtained between 8K and 32K, which would limit the size a little more if you want maximum performance (but it changes little and depends on the scenario).

The biggest scalability problem of Sqlite is when you need a very large amount of competing scripts. Because its locking lacks granularity, any attempt at recording prevents other writing even at points that are not in competition. It doesn’t affect reading unless you’re not using WAL, which is recommended in almost every situation.

The data type does not influence the limit, only the size occupied. Of course each type has its own limit.

  • Reading my question again, maybe today I didn’t even ask this question...hahaha, I believe that today it is much more feasible to use Apis Rest and use the front as the shell of the app.. Sqlite would serve only for simple things. Very good!

Browser other questions tagged

You are not signed in. Login or sign up in order to post.