On 21 November 2011 13:41, SupportLists <supportli...@qlands.com> wrote: > Hi, > > I am trying to use sqlite3 command shell with -init filename. > > The file has: > > CREATE TABLE griddata (id_suit VARCHAR(14) PRIMARY KEY,xpos DECIMAL(7),ypos > DECIMAL(7),cellvalue DECIMAL(14,5) DEFAULT -9999); > .separator "," > .import /home/cquiros/temp/layers/layers/New/lgp001.csv griddata > ALTER TABLE griddata ADD COLUMN colour char(9); > ALTER TABLE griddata ADD COLUMN classCode integer; > .quit > > All the commands works except .quit . How can I execute the shell with a > -init and then exit when it finished processing the file?
sqlite3 -init filename tst.db ".quit" or sqlite3 tst.db ".read filename" > > Many thanks, > Carlos. Regards, Simon _______________________________________________ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users