Re: Needless additional partition check in INSERT?
От | Alvaro Herrera |
---|---|
Тема | Re: Needless additional partition check in INSERT? |
Дата | |
Msg-id | 20180608184122.opplyrcgw74pjjsh@alvherre.pgsql обсуждение исходный текст |
Ответ на | Re: Needless additional partition check in INSERT? (David Rowley <david.rowley@2ndquadrant.com>) |
Ответы |
Re: Needless additional partition check in INSERT?
Re: Needless additional partition check in INSERT? |
Список | pgsql-hackers |
On 2018-Jun-09, David Rowley wrote: > Of course, that could be fixed by adding something like "bool > isinsert" to ExecConstraints(), so that it does not do the needless > check on UPDATE, Yeah, that was my actual suggestion rather than using Amit's patch verbatim. > but I'm strongly against the reduction in modularity. > I quite like ExecConstraints() the way it is. I see. Maybe this business of sticking the partition constraint check in ExecConstraints was a bad idea all along. How about we rip it out and move the responsibility of doing ExecPartitionCheck to the caller instead? See attached. This whole business looks much cleaner to me this way. BTW, while working on this, I was a bit disturbed by the execReplication.c changes (namely: if the partitioning is not identical on both sides, things are likely to blow up pretty badly), but that's a separate topic. I didn't see any tests of logical replication with partitioned tables ... Is the current understanding that we don't promise those things to work terribly well together? -- Álvaro Herrera https://www.2ndQuadrant.com/ PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services
Вложения
В списке pgsql-hackers по дате отправления: