Search Postgresql Archives

Re: CSVQL? CSV SQL? tab-separated table I/O? RENAME COLUMN

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, May 2, 2018 at 4:29 PM, Jim Michaels <jmichae35@xxxxxxxxx> wrote:
what do you think about foreign data wrappers getting CSV file table I/O?
- I had thought that CSVQL db could be implemented completely with
​<snip>

​I don't know what you want to do with this. SQLite already supports it. SQLite is an embedded SQL database​ software. To a great extent, the SQL that it understands is similar to what PostgreSQL understands. It is one of the "standards" that the author uses. It implements "virtual tables" via extensions. One of these is to process CSV files. ref: http://sqlite.org/csv.html  The CSV it understands is RFC 4180 format (https://www.ietf.org/rfc/rfc4180.txt). SQLite is open source and is _PUBLIC DOMAIN_. That is, it has NO copyright at all. So you can do anything with it that you want to. You might even be able to use the source to the SQLite extension ( https://www.sqlite.org/src/artifact?ci=trunk&filename=ext/misc/csv.c ) to write the PostgreSQL foreign data wrapper.

So, if you just need something so that you can read a CSV using SQL, then you might consider using SQLite instead of, or in addition to, PostgreSQL. Or, if you need to do subselects, unions, or other things containing both PostgreSQL data & CSV data, then I guess you're stuck with the foreign data wrapper. 

 

--
======
Jim Michaels <jmichae35@xxxxxxxxx>




--
We all have skeletons in our closet.
Mine are so old, they have osteoporosis.

Maranatha! <><
John McKown

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]

  Powered by Linux