~/SQLite CLI Essential Commands
Feb 15, 2021
The SQLite CLI lets you manage databases directly from your terminal. Here are the main commands to use.
Starting the CLI
Start by running:
|
|
Viewing Tables
List all tables:
|
|
Schema Information
See the schema of a table:
|
|
Running SQL Queries
Example of a typical query:
|
|
Import Data
Import CSV data:
Export Data
Export results to a file:
Exiting the SQLite CLI
Exit with:
|
|
or
|
|
Read more in the official SQLite documentation.