Change SQLite default settings

2019-01-30 13:12发布

问题:

we know when type .mode column let me see tables like column And .headers on , we can see the header of tables. But I want to know if there is any way make the two default settings?

Do some modify for the source code of sqlite?? OR is there a config file for these settings?

回答1:

Put:

.headers on
.mode column

In a file called .sqliterc in the home directory of the user running sqlite.

(P.S. I found that in man sqlite3.)



标签: sqlite3