From: | ivan <iv(at)psycho(dot)pl> |
---|---|
To: | pgsql-hackers(at)postgreSQL(dot)org |
Subject: | arrays |
Date: | 2003-07-27 20:44:25 |
Message-ID: | Pine.LNX.4.56.0307272234060.31026@rex.anfa.pl |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
hi :>
i wrote function to change array to setof record, because better is
working with tuples .
http://www.psycho.pl/public/src/pgsql/array.tar.bz2
i will very glade when you check this , because im afraid thed i make same
mistakes .. (if its good ist could be added to contrib/array as one more
funciton)
its good to select like this (im writing from mem, not coping so sorry for
mistakes in names)
SELECT * FROM pg_catalog.pg_type t inner join pg_catalog.pg_namespace n ON
(t.typnamespace=n.oid) WHERE pg_type = 'my_type' AND n.nspname IN (SELECT
a FROM ( array_to_setof(current_schemas()) ) s (schema name));
declaration is setof record array_to_setof ( anyarray);
i trayed created it like "any" array_to_setof( anyarray) but i had problem
with select. i also trying write setof_to_array as aggregate, but i have
problem with returns type , because aggregate cat have 'anyarray' as
result ;(
thx for your opionion.
bye
From | Date | Subject | |
---|---|---|---|
Next Message | Robert Creager | 2003-07-27 21:31:02 | Re: FAQ programming entry? |
Previous Message | Mendola Gaetano | 2003-07-27 20:39:15 | Re: postmaster core ( finally I have it ) [ vacuum pg_rewrite ] |