Simple sqlite performance test, sqlite Performance
It mainly tests the performance of sqlite insertion and query in large data volumes:
Test environment: Centos6.4 1 GB memory single-core
Data Volume |
Size |
Index Field Retrieval (Time consumed) |
Non-index Field Retrieval (Time consumed) |
Total insertion time |
10 W |
19 M |
0.001 s |
0.036 s |
5.1 s |
50 W |
100 M |
0.0014 s |
0.147 s |
32.21 s |
100 million |
200 M |
0.0009 s |
5.277 s |
63.29 s |
200 million |
400 M |
0.0008 s |
12.51 s |
130.2 s |
500 million |
1002 M |
0.0016 s |
17.3 s |
513.1 s |
1000 million |
2G |
0.0009 s |
63.0 s |
1278.24 s |
2000 million |
3.9 GB |
0.0025 s |
134.1 s |
3080.6 s |
5000 million |
9.8 GB |
0.0055 s |
334.078 s |
11745.68 s |
According to the experiment results, sqlite has excellent performance in terms of tens of millions of data records.
As an embedded database, it has significant advantages: 1. single database file; 2. Lightweight; 3. cross-platform; 4. Support for TB-level data; 5. independent from other software.
Copyright Disclaimer: This article is an original article by the blogger and cannot be reproduced without the permission of the blogger.