Re: Impossible with pl/pgsql?
| От | Michael Fuhr | 
|---|---|
| Тема | Re: Impossible with pl/pgsql? | 
| Дата | |
| Msg-id | 20050530161332.GA78929@winnie.fuhr.org обсуждение исходный текст  | 
		
| Ответ на | Impossible with pl/pgsql? (Markus Bertheau ☭ <twanger@bluetwanger.de>) | 
| Список | pgsql-sql | 
On Mon, May 30, 2005 at 05:15:55PM +0200, Markus Bertheau ??? wrote: > > Now how would a query look like that involves find() and decorate() and > returns > > id | name | author | last_change > -------------------------------- > 4 | egg | john | 2003-05-05 > 5 | ham | dave | 2004-03-01 Either of the following should work in PostgreSQL 8.0 and later: SELECT (decorate(x)).* FROM find() AS f(x); SELECT (decorate(find)).* FROM find(); A downside is that decorate() will be called once for each output column in each row, as can be seen by adding debugging RAISE statements. So in your example it would be called eight times (2 rows * 4 columns) instead of twice (once for each of 2 rows). -- Michael Fuhr http://www.fuhr.org/~mfuhr/
В списке pgsql-sql по дате отправления: