Re: functions returning records

From: Karel Zak <zakkr(at)zf(dot)jcu(dot)cz>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Jan Wieck <JanWieck(at)Yahoo(dot)com>, Alex Pilosov <alex(at)pilosoft(dot)com>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: functions returning records
Date: 2001-06-28 07:41:11
Message-ID: 20010628094111.D27259@ara.zf.jcu.cz
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers


The other thing:

1/ SELECT a, b, c FROM foo();
2/ SELECT a FROM foo();

How result (build and) returns function foo() in example 1/ and 2/ ?

It's bad functions if returns same result for both queries -- because
in example 2/ is wanted only one columns. IMHO function returning
records needs information about wanted result (number of columns, etc).

For example trigger functions has specific information by
"CurrentTriggerData" struct. For functions returning records we can
create special struct too. What?

Karel

--
Karel Zak <zakkr(at)zf(dot)jcu(dot)cz>
http://home.zf.jcu.cz/~zakkr/

C, PostgreSQL, PHP, WWW, http://docs.linux.cz, http://mape.jcu.cz

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Jan Wieck 2001-06-28 11:50:26 Re: functions returning records
Previous Message Hannu Krosing 2001-06-28 06:33:24 Re: Re: 7.2 items