Questions tagged [sqlite]

SQLite is an in-process library that implements a self-contained, serverless, zero-configuration, transactional SQL database engine.

SQLite is an embedded SQL database engine. Unlike most other SQL databases, SQLite does not have a separate server process. SQLite reads and writes directly to ordinary disk files. A complete SQL database with multiple tables, indices, triggers, and views, is contained in a single disk file. The database file format is cross-platform - you can freely copy a database between 32-bit and 64-bit systems or between big-endian and little-endian architectures. These features make SQLite a popular choice as an Application File Format.

Think of SQLite not as a replacement for Oracle but as a replacement for fopen()

Executive Summary

102 questions
73
votes
9 answers

Why do I get sqlite error, "unable to open database file"?

Using my Django app, I'm able to read from the database just fine. When the application didn't have permission to access the file, it gave me this error: attempt to write a readonly database Which made sense. So I edited the permissions on the…
Nick Bolton
  • 5,016
  • 12
  • 51
  • 62
31
votes
1 answer

How can I verify that a SQLite db3 file is valid/consistent

I have some sqlite version3 db3 files I copied off a live running production system (I know bad sysadmin bad sysadmin) for various reasons. Is there some sqlite command I can run that will verify that all the data can be read out of these files (I…
hellomynameisjoel
  • 2,170
  • 1
  • 18
  • 23
13
votes
4 answers

How do I enable SQLite on Linux/Apache/PHP?

To enable SQLite on my Windows/Apache/PHP setup, I uncomment the following lines in the php.ini file and restart Apache: extension=php_pdo.dll extension=php_pdo_sqlite.dll Now I have a VPS with Suse Linux 10.3 and Apache/PHP was set automatically.…
Edward Tanguay
  • 1,139
  • 4
  • 20
  • 30
10
votes
1 answer

How can I convert an MS Access database (.mdb) file to a Sqlite database (.db) file?

Can anybody help me convert an MS Access (.mdb) file to an Sqlite database (.db) file? I need to convert all the tables and dump the data inside. Are there any tools available, or is there any API which converts .mdb to .db?
Rajendar
  • 101
  • 1
  • 1
  • 3
9
votes
5 answers

SQLite on a production server?

I have known about SQLite for a long time and I know it is blazing fast, but I have never tried it in a production server. I was never able to find a solid estimate on how much traffic it could handle before failing. Does anyone have any numbers or…
Dr Hydralisk
  • 315
  • 3
  • 7
8
votes
2 answers

Install sqlite latest version on Centos6.7

I'm trying to install the latests versions of sqlite (> 3.7.5) under Centos 6.7. So when I launch install command : yum install sqlite I get the following Message : Package sqlite-3.6.20-1.el6_7.2.x86_64 already installed and latest version …
Zakaria Acharki
  • 183
  • 1
  • 1
  • 8
8
votes
2 answers

How to Link an SQL Server 2008 Server to an SQLite Server?

I want to "Link" an SQLite server with an SQL Server 2008 server. E.g. using the sp_addlinkedserver command. How do I do this? I have searched far and wide, but found no solution for this problem. The closest attempt I have found is…
8
votes
1 answer

Linux/ext4/sqlite: Can touching a file while it's being written to cause a race condition?

For context: I need to be able to reliably update the timestamp on some sqlite DB files which get intermittent updates on an ext4 filesystem. Can using the touch command (to update the last modification time) fail when the database is being written…
Hart Simha
  • 1,183
  • 7
  • 7
7
votes
8 answers

Is this idea about distributed database server with centralized storage feasible?

I often use SQLite for creating simple programs in companies. The database is placed on a file server. This works fine as long as there are not more than about 50 users working towards the database concurrently (though depending on whether it is…
David
  • 437
  • 1
  • 5
  • 11
6
votes
1 answer

Enabling sqlite3 in php7

I want to enable sqlite3 in php.ini but when I try to load a PHP script this error happens: PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib/php/20151012/sqlite.so' - /usr/lib/php/20151012/sqlite.so: cannot open shared object…
user472823
6
votes
4 answers

Can SQLite be used with GlusterFS?

I want to build a distributed storage based on GlusterFS with Automatic File Replication (AFR) to store users files in a fault-tolerant way. But I also want to access an SQLite3 database stored on the GlusterFS volume (and so replicated on several…
math
  • 197
  • 3
  • 7
5
votes
1 answer

How can I test whether fcntl() locks work with my NFS setup?

From the SQLite FAQ: Can multiple applications or multiple instances of the same application access a single database file at the same time? … SQLite uses reader/writer locks to control access to the database. … But use caution: this locking…
200_success
  • 4,701
  • 1
  • 24
  • 42
5
votes
9 answers

Why class 'SQLiteDatabase' is not found in /var/www/*.php?

I am trying to use sqlite from PHP. I have the following simple code: As the result of this code (which I execute in the command line "php test2.php") I get: Fatal error: Class…
Roman
  • 2,439
  • 9
  • 32
  • 32
4
votes
2 answers

SQLite on Google Cloud Persistent Disk

Does Google's Persistent Disk have proper reader/writer locks for concurrent access (many virtual machines accessing data from a single Persistent Disk) which is required for SQLite? According to the SQLite FAQ: SQLite uses reader/writer locks to…
Jon
  • 143
  • 1
  • 5
4
votes
3 answers

Inserting multiple lines into a sqlite column with bash script

I am trying to insert a value into my sqlite DB that consists of multiple lines and special characters. For example: { "foo"="$BAR" } I have been using the sqlite3 command but I dont know how to get this in. Also within my bash script I have…
JpaytonWPD
  • 141
  • 1
  • 6
1
2 3 4 5 6 7