pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Bricklen Anderson <banderson@presinet.com>
To: Naomi Walker <nwalke@eldocomp.com>
Cc: pgsql-admin@postgresql.org <pgsql-admin@postgresql.org>
Subject: Re: Simple Unload
Date: Mon, 11 Dec 2006 13:19:05 -0800
Message-ID: <457DCB49.300@presinet.com> (raw)
In-Reply-To: <457DC371.8060107@eldocomp.com>
References: <a97c77030612082203j5b1dac19i96ef9932d60f375e@mail.gmail.com>
	<8397.1165647371@sss.pgh.pa.us>
	<a97c77030612082307l10eee309n6bd8ad15e992b3c2@mail.gmail.com>
	<a97c77030612082320v733b0bbav5ed2828edbc95a8d@mail.gmail.com>
	<18891.1165686391@sss.pgh.pa.us>
	<1165865427.3816.90.camel@silverbirch.site>
	<457DC371.8060107@eldocomp.com>

Naomi Walker wrote:
> From time to time, I need to unload rows to a delimited file,
> specifically with a "where" clause.
> I've cobbled a script together to do this, but it seems like a
> reasonable utility to support. Sort
> of a pg_dump on steroids..
> 
> Have I missed the simple way to do this?  Would someone consider adding
> such a utility or adding
> this to pg_dump?
> 
> Naomi

8.2 COPY appears to be able to output in csv format, using a WHERE 
clause, though I've not tried it.

http://www.postgresql.org/docs/8.2/static/sql-copy.html



view thread (2+ messages)

Message-ID: <457DCB49.300@presinet.com>
Permalink:  ../457DCB49.300@presinet.com/
Also on:    postgresql.org/message-id/457DCB49.300@presinet.com

 · 

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 from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-admin@postgresql.org
  Cc: banderson@presinet.com, nwalke@eldocomp.com
  Subject: Re: Simple Unload
  In-Reply-To: <457DCB49.300@presinet.com>
  References: <a97c77030612082203j5b1dac19i96ef9932d60f375e@mail.gmail.com> <8397.1165647371@sss.pgh.pa.us> <a97c77030612082307l10eee309n6bd8ad15e992b3c2@mail.gmail.com> <a97c77030612082320v733b0bbav5ed2828edbc95a8d@mail.gmail.com> <18891.1165686391@sss.pgh.pa.us> <1165865427.3816.90.camel@silverbirch.site> <457DC371.8060107@eldocomp.com> <457DCB49.300@presinet.com>

* 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