Re: [BUGS] BUG #14350: VIEW with INSTEAD OF INSERT TRIGGER and COPY. Missing feature or working as designed.

Поиск
Список
Период
Сортировка
От Dilip Kumar
Тема Re: [BUGS] BUG #14350: VIEW with INSTEAD OF INSERT TRIGGER and COPY. Missing feature or working as designed.
Дата
Msg-id CAFiTN-vcDoayjDfttY0PFMneWGFD2r3M=9SR_pG3rpTR8LWy3g@mail.gmail.com
обсуждение исходный текст
Ответ на Re: [BUGS] BUG #14350: VIEW with INSTEAD OF INSERT TRIGGER and COPY. Missing feature or working as designed.  (Haribabu Kommi <kommi.haribabu@gmail.com>)
Ответы Re: [BUGS] BUG #14350: VIEW with INSTEAD OF INSERT TRIGGER and COPY. Missing feature or working as designed.
Список pgsql-hackers
On Thu, Nov 3, 2016 at 9:57 AM, Haribabu Kommi <kommi.haribabu@gmail.com> wrote:
> Thanks for your suggestion. Yes, I agree that adding a hint is good.
> Updated patch is attached with addition of hint message.
>
> 2016-11-03 14:56:28.685 AEDT [7822] ERROR:  cannot copy to view "ttt_v"
> 2016-11-03 14:56:28.685 AEDT [7822] HINT:  To enable copy to view, provide
> an INSTEAD OF INSERT trigger
> 2016-11-03 14:56:28.685 AEDT [7822] STATEMENT:  COPY ttt_v FROM stdin;

Okay, Patch in general looks fine to me. One cosmetic comments, IMHO
in PG we follow operator at end of the line, so move '&&' to end of
the previous line.

+ if (cstate->rel->rd_rel->relkind != RELKIND_RELATION
+ && (!cstate->rel->trigdesc ||
+ !cstate->rel->trigdesc->trig_insert_instead_row))

Meanwhile I will test it and give the feedback.

-- 
Regards,
Dilip Kumar
EnterpriseDB: http://www.enterprisedb.com



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

Предыдущее
От: Thomas Munro
Дата:
Сообщение: Re: WIP: [[Parallel] Shared] Hash
Следующее
От: Kuntal Ghosh
Дата:
Сообщение: Re: WAL consistency check facility