Normally I use these settings to have SQLite
output pretty structure:
sqlite> .mode column
sqlite> .headers on
But how to make them default settings?
To set default value for a column in SQLite, use DEFAULT :CREATE TABLE customers ( id INTEGER PRIMARY KEY, store_code TEXT DEFAULT "store1" NOT NULL, name TEXT );
The . mode command sets the output mode. This determines how the output data is formatted and presented. The optional table name is only used by the insert mode. The default mode is list .
(10) Does SQLite support a BLOB type? SQLite allows you to store BLOB data in any column, even columns that are declared to hold some other type. BLOBs can even be used as PRIMARY KEYs.
From the man page.
If the file
~/.sqliterc
exists, it is processed first. can be found in the user's home directory, it is read and processed. It should generally only contain meta-commands.
So put them into ~/.sqliterc
.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With