Re: populate table with large csv file - Mailing list pgsql-general

From P.J. \"Josh\" Rovero
Subject Re: populate table with large csv file
Date
Msg-id 3F731CF0.2090800@sonalysts.com
Whole thread Raw
In response to populate table with large csv file  ("Dave [Hawk-Systems]" <dave@hawk-systems.com>)
Responses Re: populate table with large csv file
List pgsql-general
Dave [Hawk-Systems] wrote:

> aside from parsing the csv file through a PHP interface, what isthe easiest way
> to get that csv data importted into the postgres database. thoughts?

Assuming the CSV file data is well formed, use psql and
the COPY command.

In psql, create the table.  Then issue command:

copy <tablename> from 'filename' using delimiters ',';
--
P. J. "Josh" Rovero                                 Sonalysts, Inc.
Email: rovero@sonalysts.com    www.sonalysts.com    215 Parkway North
Work: (860)326-3671 or 442-4355                     Waterford CT 06385
***********************************************************************


pgsql-general by date:

Previous
From: Joe Conway
Date:
Subject: Re: populate table with large csv file
Next
From: maufaini@tiscali.it (Maurizio Faini)
Date:
Subject: Re: GET LAST ID INSERT