Re: How to import a CSV file (originally from Excel) - Mailing list pgsql-general

From Magnus Hagander
Subject Re: How to import a CSV file (originally from Excel)
Date
Msg-id 6BCB9D8A16AC4241919521715F4D8BCEA3529C@algol.sollentuna.se
Whole thread Raw
Responses Re: How to import a CSV file (originally from Excel)  (Craig White <craigwhite@azapple.com>)
List pgsql-general
> > \copy "Flight Traffic" from yourfile.csv delimiter as ','
> csv quote as
> > '"'
> >
> > (might need some adaption, of course)
> >
> >
> > Loading 45,000 lines is trivial for copy, it shouldn't take
> noticable
> > time at all.
> ----
> along these lines - can I do something similar (CSV file) but
> 'update' 2 or 3 columns?

I'd use COPY to a temp table, then run a normal UPDATE on that.

//Magnus

pgsql-general by date:

Previous
From: Janning Vygen
Date:
Subject: Hardware related question: 3ware 9500S
Next
From: "Ian Harding"
Date:
Subject: Leverage your PostgreSQL V8.1 skills to learn DB2