Sub-query as function argument

Поиск
Список
Период
Сортировка
От Michael Burke
Тема Sub-query as function argument
Дата
Msg-id 200512200942.51624.michael@engtech.ca
обсуждение исходный текст
Ответы Re: Sub-query as function argument  (Jaime Casanova <systemguards@gmail.com>)
Re: Sub-query as function argument  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-sql
Is it possible to execute a SELECT query as an argument to a function?

Example:

SELECT my_func('Sample', NULL, SELECT MIN(year) FROM audio);

In my particular case, my_func inserts columns into another table; I wish to 
use values from another table as the arguments.  The interior SELECT will 
return only a single value; perhaps it needs to be wrapped in another 
function?

TIA.
Mike.

-- 
Michael Burke
michael@engtech.ca


В списке pgsql-sql по дате отправления:

Предыдущее
От: Aarni Ruuhimäki
Дата:
Сообщение: Re: Querying date_time for date only ?
Следующее
От: Jaime Casanova
Дата:
Сообщение: Re: Sub-query as function argument