You need to

.mode insert <tablename>
SELECT * FROM <tablename>;

Repeat for all your tables.

-----Ursprüngliche Nachricht-----
Von: sqlite-users [mailto:sqlite-users-boun...@mailinglists.sqlite.org] Im 
Auftrag von Luca Ferrari
Gesendet: Freitag, 02. August 2019 10:04
An: SQLite <sqlite-users@mailinglists.sqlite.org>
Betreff: [EXTERNAL] [sqlite] mode insert dumps

Hi,
I've got a lot of database files that I would like to dump using INSERT 
statements.
unluckily, .mode insert does not work for me, or I'm not able to understand how 
it works.

sqlite> select mude_anno, mude_numero from catdaemo;
INSERT INTO table VALUES(2019,1161);

My questions are:
1) why is the insert operating against "table" instead of the real table I was 
selecting from (catdaemo)?
2) is there a way to force the INSER to have also the columns I selected 
listed? I would like something like:
INSERT INTO catadaemo( mude_anno, mude_numero ) VALUES(2019,1161);

The reason is that I want to exclude automatic keys from my inserts because I'm 
going to pump those inserts into another database with automatic keys.

Thanks,
Luca
_______________________________________________
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users


___________________________________________
 Gunter Hick | Software Engineer | Scientific Games International GmbH | 
Klitschgasse 2-4, A-1130 Vienna | FN 157284 a, HG Wien, DVR: 0430013 | (O) +43 
1 80100 - 0

May be privileged. May be confidential. Please delete if not the addressee.
_______________________________________________
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to