Re: wishlist for 8.4

Поиск
Список
Период
Сортировка
От Richard Huxton
Тема Re: wishlist for 8.4
Дата
Msg-id 47B56439.6060105@archonet.com
обсуждение исходный текст
Ответ на Re: wishlist for 8.4  (Decibel! <decibel@decibel.org>)
Ответы Re: wishlist for 8.4  (David Fetter <david@fetter.org>)
Re: wishlist for 8.4  (James Mansion <james@mansionfamily.plus.com>)
Список pgsql-hackers
Decibel! wrote:
> On Feb 14, 2008, at 10:06 AM, Tom Lane wrote:
>> Raphaël Jacquot <sxpert@sxpert.org> writes:
>>> so, I propose the use of
>>>     NEW[variable_containing_the_column_name]
>>> (which can obviously be extended to any tuples)
>>> to allow such access.
>>
>>> what do you experts think ?
>>
>> Zero chance.  plplgsql is a strongly typed language, and a construct
>> like that couldn't have any known-in-advance data type.
> 
> Would it be reasonable to teach EXECUTE about NEW and OLD? That should 
> allow the OP to do what he's looking for...

You could have a function get_attribute_as_text(NEW, 'id') or even 
get_attribute_quoted(NEW, 'id')

It would be nice to have a more dynamic language built-in. I'm not aware 
of any BSD-licensed dynamic languages though.

--   Richard Huxton  Archonet Ltd


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

Предыдущее
От: Simon Riggs
Дата:
Сообщение: Re: Reworking WAL locking
Следующее
От: Grzegorz Jaskiewicz
Дата:
Сообщение: subquery in limit