
With minimal line editing and typing, that gets the non-header data in. import -csv -skip 1 path/to/my.csv StagingTable import -csv -autocolumns path/to/my.csv StagingTable It may be useful for those without header rows, but with headers in the data that would be throwing out the baby with the bathwater. I'm not feeling much improvement with your -autocolumns option in this case. So, I'm sympathetic to the plight of those who want to get such done without a lot of futzing and would like to understand those scenarios and how possible a new features would play out in them.

I also have used the SQLite CLI for plenty of quick-and-dirty tasks, along with perl, head, sed, and etc. I don't think that has been a priority for the CLI's design. This feature would be catering to quick-and-dirty data munging tasks. import, or read in as data and skipped when further processing the new table via SELECT. Then, either the first CSV row can be skipped on. It would create a new table, with column count conformed to the input, but with columns named "col_#" where '#' is an ascending integer starting with 1. import, is to add an option, -autocolumns, to the. What I think would be a good solution, for the OP and others who have CSV with rubbish as the first line but do not wish to count its columns and define a table prior to. (I must grant that the OP's assumed instance of it and your example are simple, but I think the result is far from Treasure anyway somebody has to figure out what to call the near-duplicate columns and/or what to do with them.) Even if the count of Garbage types was reasonably small, it would be hard to anticipate it.

(That's Garbage-In, Treasure-Out) There is no end to ad-hoc methods for recognizing and transforming Garbage that is not completely random junk. I shudder to think of getting into the GITO business. There is a simple solution today, which is just to create the table before the. The option to auto-generate a table definition, given the presumed presence of legitimate column names in the first CSV record, is a convenience for those who have the quite common CSV format with appropriate column names. I think the answer needs to be similar though. (An example such as yours makes all the difference.) Ok, I read the OP's statement of difficulty another way.
