pg.ddx.io  pgsql-interfaces@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Lamar Owen <lamar.owen@wgcr.org>
To: Adam Lang <aalang@rutgersinsurance.com>
Cc: pgsql-interfaces@postgresql.org
Subject: Re: imorting csv files into postgres
Date: Thu, 18 Jan 2001 16:55:55 -0500
Message-ID: <3A67666B.423F14CF@wgcr.org> (raw)
References: <E14JIp9-0003RL-00@mail1.mailshot>
	<3A67568B.59572A40@wgcr.org>
	<020401c08196$40c677c0$330a0a0a@6014cwpza006>

Adam Lang wrote:
> Yeah, but he doesn't want to have to create the table before hand, he wants
> postgresql to do all the work. ;)
 
> The only way that I know of to do that is write a program and feed it the
> CSV file... but in the program it is going to need to create the table.

I have such a script for AOLserver Tcl that does all the work.  But it
requires a working AOLserver/PostgreSQL installation, which will take
longer to set up than a simple perl script would take to be written. 
The hard part is the CSV parsing -- creating the table and filling in
the data is easy in comparison, especially in the Pg perl interface.
--
Lamar Owen
WGCR Internet Radio
1 Peter 4:11



view thread (4+ messages)

Message-ID: <3A67666B.423F14CF@wgcr.org>
Permalink:  ../3A67666B.423F14CF@wgcr.org/
Also on:    postgresql.org/message-id/3A67666B.423F14CF@wgcr.org

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-interfaces@postgresql.org
  Cc: lamar.owen@wgcr.org, aalang@rutgersinsurance.com
  Subject: Re: imorting csv files into postgres
  In-Reply-To: <3A67666B.423F14CF@wgcr.org>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox