UPSERT on view does not find constraint by name

Поиск
Список
Период
Сортировка
От Jeremy Finzel
Тема UPSERT on view does not find constraint by name
Дата
Msg-id CAMa1XUhaGQugY9yWboGXNzi+tefqC6YFmD0X04Sc8xNVQXunFw@mail.gmail.com
обсуждение исходный текст
Ответы Re: UPSERT on view does not find constraint by name  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
I'm not sure if this can be considered a bug or not, but it is perhaps unexpected.  I found that when using a view that is simply select * from table, then doing INSERT ... ON CONFLICT ON CONSTRAINT constraint_name on that view, it does not find the constraint and errors out.  But it does find the constraint if one lists the columns instead.

I did not find any mention of this specifically in the docs, or any discussion on this topic after a brief search, and I have already asked my stakeholder to change to using the column list as better practice anyway.  But in any case, I wanted to know if this is a known issue or not.

Thanks!
Jeremy

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

Предыдущее
От: Alvaro Herrera
Дата:
Сообщение: Re: Compressed pluggable storage experiments
Следующее
От: Julien Rouhaud
Дата:
Сообщение: Non working timeout detection in logical worker