To import a csv file with headers into an existing table, you can use
.import '| tail -n +2 yourfile.csv' yourtable
to skip the header line.
On Sat, Feb 29, 2020, 4:30 AM Christof Böckler wrote:
> Hi,
>
> I want to share some thoughts and make some suggestions about the SQLite
> 3 command line
On Sat, Feb 29, 2020 at 1:42 PM Shawn Wagner
wrote:
> To import a csv file with headers into an existing table, you can use
> .import '| tail -n +2 yourfile.csv' yourtable
> to skip the header line.
On unix. And by shell’ing out to native tools, so not portable.
The cli ought to have something
On Feb 27, 2020, at 11:51 PM, Christof Böckler wrote:
>
> 1. There should be no penalty for using header lines in CSV files. Thus a new
> flag -h for .import is much appreciated.
More than that, SQLite should be able to *actively use* the header when present.
For instance, given:
foo,bar,qux
3 matches
Mail list logo