Import zipped csv file

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Import zipped csv file

gwenn-6
Hello,
Is it possible to mix zipfile and csv extensions ?
sqlite> SELECT data FROM zipfile('csv_file.zip');
works.
sqlite> .shell unzip csv_file.zip
sqlite> CREATE VIRTUAL TABLE test USING csv(filename='csv_file.csv');
works.
How to pass the data extracted by zipfile to csv extension ?
Thanks.
_______________________________________________
sqlite-users mailing list
[hidden email]
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users
Reply | Threaded
Open this post in threaded view
|

Re: Import zipped csv file

Richard Hipp-3
On 4/6/18, gwenn <[hidden email]> wrote:
> Hello,
> Is it possible to mix zipfile and csv extensions ?
> sqlite> SELECT data FROM zipfile('csv_file.zip');
> works.
> sqlite> .shell unzip csv_file.zip
> sqlite> CREATE VIRTUAL TABLE test USING csv(filename='csv_file.csv');
> works.
> How to pass the data extracted by zipfile to csv extension ?
> Thanks.

I don't think that can be done right now.  It will require an
enhancement to the csv virtual table.  I have your request.

--
D. Richard Hipp
[hidden email]
_______________________________________________
sqlite-users mailing list
[hidden email]
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users