Hello,

When .importing from a csv file (for example) with a command like ".import data.csv data" if the table does not exist, the table is created using the first row of data.csv as the field names. But if the same file is imported a second time, the first line is treated as data.

My suggestion is to recognize if the first line matches the current table field names, and only if not, treat it as data. This is because one often gets the same CSV (for example) file format, and while the first run correctly creates the table, consequent updates insert dummy records (the first line which is the header.)

Thanks.

PS. By the way, any progress on the shell enhancement to load/save blobs? This will make the shell capable of handling any database without the need for external programs.

_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to