Updatable Views and INSERT INTO ... ON CONFLICT

Поиск
Список
Период
Сортировка
От Joel Jacobson
Тема Updatable Views and INSERT INTO ... ON CONFLICT
Дата
Msg-id ddd29182-86fb-4c2b-a930-85dcfe2272d0@www.fastmail.com
обсуждение исходный текст
Ответы Re: Updatable Views and INSERT INTO ... ON CONFLICT  (walther@technowledgy.de)
Список pgsql-hackers
Hi,

I note it's not yet possible to INSERT INTO an Updatable View using the ON CONFLICT feature.

One imaginable pattern is when a user wants to refactor by renaming a table,
but for some reason cannot refactor some specific application and want to
allow it to continue to use the table's old name.

One approach to do so would be to create a an Updatable View (aka Simple view) [1],
given the same name as the table's old name.

This is ugly and not something I would do myself, but I've read about how others describe this pattern, not in the context of ON CONFLICT, but in general, when refactoring.

Are there reasons why it would not be possible to develop support INSERT INTO ... ON CONFLICT for Updatable Views?

Not saying it is desired, just trying to better understand the limits of Updatable Views.

/Joel

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

Предыдущее
От: "Joel Jacobson"
Дата:
Сообщение: Re: Foreign key joins revisited
Следующее
От: Zhihong Yu
Дата:
Сообщение: Re: Collecting statistics about contents of JSONB columns