pgsql functions: get column headers; optional arguments

From: Mark <mark(at)manngo(dot)net>
To: pgsql-general(at)postgresql(dot)org
Subject: pgsql functions: get column headers; optional arguments
Date: 2007-08-24 13:28:24
Message-ID: 46CEDCF8.6070404@manngo.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Hi. I hope this is the correct mailing list.

I am writing a function to extract data either from a table or a query
and output it in xml. I have the logic down, but I cannot work out a few
things.

1. How can I read the column headings from the returned data set? I have
resorted to writing the same function in tcl in which I can work out how
to do this, but what about pgsql? I can't use the system tables for
this, since the data may not come from a table.

2. It it possible, either in tcl or pgsql, to have optional function
arguments?

Thanks,

Mark
--

Mark Simon

Manngo Net Pty Ltd

Phone/Fax: 1300 726 000
mobile: 0411 246 672

email: mark(at)manngo(dot)net <mailto:mark(at)comparity(dot)net>
web: http://www.manngo.net

Resume: http://mark.manngo.net

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Gregory Stark 2007-08-24 14:02:32 Re: FATAL: could not reattach to shared memory (Win32)
Previous Message Richard Huxton 2007-08-24 13:26:44 Re: Local authentication/security