0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 1 year has passed since last update.

sqlite3 command memo

Last updated at Posted at 2022-07-31

sqlite3 memo

よく使うコマンド for sqlite3.

1. BASIC

> sqlite3 DATABESE.db
CREATE TABLE table1(col1 STRING, col2 INTEGER) -- create table

SELECT * from table1; -- get contents

SELECT col1 FROM table1 WHERE col2 = 3; -- with conditions

PRAGMA table_info('table1'); -- table info.
.tables -- show all tables

DROP TABLE 'table1'; -- delete table

.exit -- stop sqlite3 command-line
0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?