[GENERAL] UPDATE column without FK fires other FK triggers constraint check

Поиск
Список
Период
Сортировка
От Luca Looz
Тема [GENERAL] UPDATE column without FK fires other FK triggers constraint check
Дата
Msg-id CAHXaXTw_2va3Dk9oT0KpEq9-t-c1MMAm0YOLhtU6ER4M31+wSw@mail.gmail.com
обсуждение исходный текст
Ответы Re: [GENERAL] UPDATE column without FK fires other FK triggers constraint check
Список pgsql-general
I was analyzing an update function and i have noticed "Trigger for constraint" entries for foreign keys that i wasn't using or referring.
After some tests it seems that this happens when the same row is covered by more than 1 update in the same transaction even without any change.

Here is a dbfiddle example:

Is this an expected behavior? Why it happens?

I have initially asked this on dba stackexchange:

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

Предыдущее
От: basti
Дата:
Сообщение: Re: [GENERAL] log_filename
Следующее
От: Mikhail
Дата:
Сообщение: [GENERAL] Index Only Scan and Heap Fetches