On 03/08/2017 12:03 AM, Rob Golsteijn wrote:
Hi List,
I want to report a minor issue for the Sqlite shell. It does not handle
multiline command line arguments in which the second line contains a
dot-command correctly.
If the same statements are passed via stdin they are handled fine.
Tested with Sqlite 3.15.2 on Ubuntu 14.04 using Bash.
Example:
Passing statements via stdin works fine:
echo "SELECT 1;
.mode csv
SELECT 1;" | sqlite3 mydb.sq3
(no error)
Passing the statements via a command line argument gives an error:
sqlite3 mydb.sq3 "SELECT 1;
.mode csv
SELECT 1;"
Error: near ".": syntax error
A work around is:
sqlite3 mydb.sq3 "SELECT 1" ".mode csv" "SELECT 1"
Dan.
_______________________________________________
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users