Re: patch: plpgsql - access records with rec.(expr)

Поиск
Список
Период
Сортировка
От Matt
Тема Re: patch: plpgsql - access records with rec.(expr)
Дата
Msg-id 1100792195.4229.125.camel@matt.kynx.org
обсуждение исходный текст
Ответ на patch: plpgsql - access records with rec.(expr)  (Matt <matt@kynx.org>)
Список pgsql-hackers
> 5. Because of the way the expression is parsed (looking for closing
> parenth), this will choke if you try and put a function in there. Would
> it be better to use curly braces '{expr}' or another character to mark
> the expression?

I lie! pgpgsql_read_expression() is smarter than that!

However, I do have another problem. If the value of the expr changes
inside a loop to a fieldname of a different type, it dies with the "type
of \"%s\" does not match that when preparing the plan" message, which is
quite true: it obviously doesn't.

Just setting expectedtypeoid to InvalidOid bombs the whole thing :(
Hrm.... the "best made plans" and all that...

Matt





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

Предыдущее
От: G u i d o B a r o s i o
Дата:
Сообщение: invalid page header
Следующее
От: Tom Lane
Дата:
Сообщение: Re: invalid page header