phpLiteAdmin v1.9.7.1 Help Documentation

SQLite Library Extensions
Creating a New Database
Tables vs. Views
Writing a Select Statement for a New View
Export Structure to SQL File
Export Data to SQL File
Add Drop Table to Exported SQL File
Add Transaction to Exported SQL File
Add Comments to Exported SQL File
Partial Indexes


SQLite Library Extensions
phpLiteAdmin uses PHP library extensions that allow interaction with SQLite databases. Currently, phpLiteAdmin supports PDO, SQLite3, and SQLiteDatabase. Both PDO and SQLite3 deal with version 3 of SQLite, while SQLiteDatabase deals with version 2. So, if your PHP installation includes more than one SQLite library extension, PDO and SQLite3 will take precedence to make use of the better technology. However, if you have existing databases that are of version 2 of SQLite, phpLiteAdmin will be forced to use SQLiteDatabase for only those databases. Not all databases need to be of the same version. During the database creation, however, the most advanced extension will be used.
Back to Top
Creating a New Database
When you create a new database, the name you entered will be appended with the appropriate file extension (.db, .db3, .sqlite, etc.) if you do not include it yourself. The database will be created in the directory you specified as the $directory variable.
Back to Top
Tables vs. Views
On the main database page, there is a list of tables and views. Since views are read-only, certain operations will be disabled. These disabled operations will be apparent by their omission in the location where they should appear on the row for a view. If you want to change the data for a view, you need to drop that view and create a new view with the appropriate SELECT statement that queries other existing tables. For more information, see http://en.wikipedia.org/wiki/View_(database)
Back to Top
Writing a Select Statement for a New View
When you create a new view, you must write an SQL SELECT statement that it will use as its data. A view is simply a read-only table that can be accessed and queried like a regular table, except it cannot be modified through insertion, column editing, or row editing. It is only used for conveniently fetching data.
Back to Top
Export Structure to SQL File
During the process for exporting to an SQL file, you may choose to include the queries that create the table and columns.
Back to Top
Export Data to SQL File
During the process for exporting to an SQL file, you may choose to include the queries that populate the table(s) with the current records of the table(s).
Back to Top
Add Drop Table to Exported SQL File
During the process for exporting to an SQL file, you may choose to include queries to DROP the existing tables before adding them so that problems do not occur when trying to create tables that already exist.
Back to Top
Add Transaction to Exported SQL File
During the process for exporting to an SQL file, you may choose to wrap the queries around a TRANSACTION so that if an error occurs at any time during the importation process using the exported file, the database can be reverted to its previous state, preventing partially updated data from populating the database.
Back to Top
Add Comments to Exported SQL File
During the process for exporting to an SQL file, you may choose to include comments that explain each step of the process so that a human can better understand what is happening.
Back to Top
Partial Indexes
Partial indexes are indexes over a subset of the rows of a table specified by a WHERE clause. Note this requires at least SQLite 3.8.0 and database files with partial indexes won't be readable or writable by older versions. See the SQLite documentation.
Back to Top