Re: [BUGS] BUG #14483: Prepared statement does not re-plan while it should
В списке pgsql-bugs по дате отправления:
| От | Tom Lane |
|---|---|
| Тема | Re: [BUGS] BUG #14483: Prepared statement does not re-plan while it should |
| Дата | |
| Msg-id | 16871.1483373067@sss.pgh.pa.us обсуждение |
| Ответ на | [BUGS] BUG #14483: Prepared statement does not re-plan while it should (cnliou9@fastmail.fm) |
| Ответы |
Re: [BUGS] BUG #14483: Prepared statement does not re-plan while itshould
|
| Список | pgsql-bugs |
cnliou9@fastmail.fm writes:
> test=# CREATE TABLE x1 (c1 INTEGER);
> CREATE TABLE
> test=# PREPARE p1 AS SELECT * FROM x1;
> PREPARE
> (
> Run this SQL in another session:
> ALTER TABLE x1 ADD c2 TEXT;
> )
> test=# EXECUTE p1;
> ERROR: cached plan must not change result type
This behavior is intentional: it's to keep applications from having to
deal with the possibility that they prepare a statement, Describe it
to find out what columns it returns, and then when they actually execute
it, it returns some other column set.
regards, tom lane
--
Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-bugs
В списке pgsql-bugs по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера