Skip site navigation (1) Skip section navigation (2)

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 (view raw or flat)
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

pgsql-hackers by date

Next:From: Jan WieckDate: 2001-06-28 11:50:26
Subject: Re: functions returning records
Previous:From: Hannu KrosingDate: 2001-06-28 06:33:24
Subject: Re: Re: 7.2 items

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group