Bruce,
Thanks for your quick reply! Between your response and George's I was able
to get exactly what I needed.
That "-E" is a wonderful option. I have already put it into my snippets
file!
Grace & Peace.
Craig
-----Original Message-----
From: pgsql-novice-owner@postgresql.org
[mailto:pgsql-novice-owner@postgresql.org] On Behalf Of Bruce Momjian
Sent: Wednesday, April 01, 2009 9:22 AM
To: Craig
Cc: pgsql-novice@postgresql.org
Subject: [personal] Re: [NOVICE] How to out \df to a file
Craig wrote:
> Hello All,
>
>
>
> I am trying to get a list of the functions built into postgreSQL.
>
> I know to use the \df command w/n psql, but paging through that is
painful.
>
> Is there a way to send the \df output to a file?
>
> Or is there a table/view (s) I could query?
psql -E will show you the query; that is in the FAQ.
$ psql -E test
psql (8.4devel)
Type "help" for help.
test=> \df
********* QUERY **********
SELECT n.nspname as "Schema",
p.proname as "Name",
pg_catalog.pg_get_function_result(p.oid) as "Result data type",
pg_catalog.pg_get_function_arguments(p.oid) as "Argument data
types"
FROM pg_catalog.pg_proc p
LEFT JOIN pg_catalog.pg_namespace n ON n.oid = p.pronamespace
WHERE p.prorettype <> 'pg_catalog.cstring'::pg_catalog.regtype
AND p.proargtypes[0] IS DISTINCT FROM
'pg_catalog.cstring'::pg_catalog.regtype
AND NOT p.proisagg
AND n.nspname <> 'pg_catalog'
AND pg_catalog.pg_function_is_visible(p.oid)
ORDER BY 1, 2, 4;
**************************
List of functions
Schema | Name | Result data type | Argument data types
--------+------+------------------+---------------------
(0 rows)
That is for Postgres 8.4.
--
Bruce Momjian <bruce@momjian.us> http://momjian.us
EnterpriseDB http://enterprisedb.com
+ If your life is a hard drive, Christ can be your backup. +
--
Sent via pgsql-novice mailing list (pgsql-novice@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-novice
No virus found in this incoming message.
Checked by AVG - www.avg.com
Version: 8.0.238 / Virus Database: 270.11.35/2033 - Release Date: 04/01/09
06:06:00