| От | Tino Wildenhain |
|---|---|
| Тема | functions marked STABLE not allowed to do INSERT |
| Дата | |
| Msg-id | 4378A70D.8050601@wildenhain.de обсуждение исходный текст |
| Ответы |
Re: functions marked STABLE not allowed to do INSERT
Re: functions marked STABLE not allowed to do INSERT |
| Список | pgsql-hackers |
New in 8.1 it seems functions marked STABLE are not allowed to have any INSERT statement in them. However in this particular case, the insert does not violate the rule: "STABLE indicates that within a single table scan the function will consistently return the same result for the same argument values, but that its result could change across SQL statements." it does basically lookup a value by a foreign key and builds a surrogate key on demand. I know I could make it volatile but otoh I really want the optimizer to optimize calls away as possible. Now, what to do beside a private revert to the patch? Regards Tino
В списке pgsql-hackers по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера