From: | Joe Conway <mail(at)joeconway(dot)com> |
---|---|
To: | Dennis King <d_r_king(at)yahoo(dot)com> |
Cc: | pgsql-novice(at)postgresql(dot)org |
Subject: | Re: Select results output to file? |
Date: | 2003-03-13 04:46:32 |
Message-ID: | 3E700D28.9070309@joeconway.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-novice |
Dennis King wrote:
> I want to output to a file, but haven't found anything but the SQL
> copy statement. I want to output the results of a select statement,
> though. Ideally I'd be doing this from inside a pl/pgsql function.
You can't do that from a plpgsql function short of writing your own C
function and calling it from there. You probably can write to a output
file from plperlu or pltclu; see:
http://www.us.postgresql.org/users-lounge/docs/7.3/postgres/plperl-trusted.html
http://www.us.postgresql.org/users-lounge/docs/7.3/postgres/pltcl.html
You can also use psql either in batch mode or interactively; see:
http://www.us.postgresql.org/users-lounge/docs/7.3/postgres/app-psql.html
Joe
From | Date | Subject | |
---|---|---|---|
Next Message | jenner viloria | 2003-03-13 06:46:33 | client |
Previous Message | Dennis King | 2003-03-13 04:37:58 | Select results output to file? |