Running queries or functions stored in a table.

Поиск
Список
Период
Сортировка
От Matthew Schumacher
Тема Running queries or functions stored in a table.
Дата
Msg-id 112f95sevl6gd81@corp.supernews.com
обсуждение исходный текст
Список pgsql-general
List,

I have a requirement to write a query that lists a set of
attribute/value pairs, but the values need to be dynamically created on
the fly from another query or function.  Is it possible to have a table
like this:

Attribute   |   Value
-------------------------
Attrib1     |   select val1, val1 from table;
Attrib2     |   func()

return this:

Attribute   |   Value
-------------------------
Attrib1     |   result1
Attrib2     |   result2

If this is possible?  How would I go about it?  I'm thinking pl/pgsql
and execute() but I'm not sure.

Any thoughts?

schu

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

Предыдущее
От: PostgreSQL PostgreSQL
Дата:
Сообщение: invalid header page in block ....
Следующее
От: Dorian Büttner
Дата:
Сообщение: Re: Postgresql driver