Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- [ramanujan:~]$cat demotab.txt
- 44 92
- 35 94
- 43 94
- 195 49
- 66 28
- 135 93
- 135 91
- 67 84
- 135 94
- [ramanujan:~]$echo "create table mytable ( col1 int, col2 int);" | sqlite3 foo.sqlite
- [ramanujan:~]$echo ".import demotab.txt mytable" | sqlite3 foo.sqlite
- [ramanujan:~]$sqlite3 foo.sqlite
- -- Loading resources from /Users/ramanujan/.sqliterc
- SQLite version 3.6.6.2
- Enter ".help" for instructions
- Enter SQL statements terminated with a ";"
- sqlite> select * from mytable;
- col1 col2
- 44 92
- 35 94
- 43 94
- 195 49
- 66 28
- 135 93
- 135 91
- 67 84
- 135 94
- sqlite> .show .separator
- echo: off
- explain: off
- headers: on
- mode: list
- nullvalue: ""
- output: stdout
- separator: "t"
- width:
- create virtual table vtYourDataset using yourModule;
- -- Bulk insert
- insert into yourTargetTable (x, y, z)
- select x, y, z from vtYourDataset;
- BEGIN;
- INSERT INTO table VALUES ();
- INSERT INTO table VALUES ();
- ...
- END;
Add Comment
Please, Sign In to add comment