| От | Tom Lane |
|---|---|
| Тема | Re: Exclusion constraint issue |
| Дата | |
| Msg-id | 28388.1285363335@sss.pgh.pa.us обсуждение |
| Ответ на | Exclusion constraint issue (Eric McKeeth <eldin00@gmail.com>) |
| Ответы |
Re: Exclusion constraint issue
Re: Exclusion constraint issue |
| Список | pgsql-general |
Eric McKeeth <eldin00@gmail.com> writes:
> why would I get the following error, since the period() function is in fact
> declared as immutable?
> test=# ALTER TABLE test3 ADD exclude using
> gist(period(effect_date::timestamptz, expire_date::timestamptz) with && );
> ERROR: functions in index expression must be marked IMMUTABLE
period() might be immutable, but those casts from date to timestamptz
are not, because they depend on the TimeZone parameter.
regards, tom lane
В списке pgsql-general по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера