All,
The current SQLite3 shell has a ".mode" directive to set the output
mode. One such mode is called "insert" which is intended to generate
INSERT statements.
The "insert" output mode is very basic, however, and lacks column names
in the output.
Attached is a patch to include the column names. This patch works for
my dataset, but I am not familiar enough with SQLite to know if it is
correct.
This addresses also a request on StackOverflow:
http://stackoverflow.com/questions/4199850/sqlite-export-with-column-names
It always outputs the column name, regardless of the ".headers" directive.
Thanks,
Roy Keene