From: | Kevin Grittner <kgrittn(at)ymail(dot)com> |
---|---|
To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
Cc: | "pgsql-hackers(at)postgreSQL(dot)org" <pgsql-hackers(at)postgreSQL(dot)org> |
Subject: | Re: matview patch readability/correctness gripe |
Date: | 2013-03-13 21:45:01 |
Message-ID: | 1363211101.67526.YahooMailNeo@web162906.mail.bf1.yahoo.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
> diff --git a/src/backend/rewrite/rewriteDefine.c
> b/src/backend/rewrite/rewriteDefine.c
> index
> a1a9808e5d94959218b415ed34c46579c478c177..896326615753f2344b466eb180080174ddeda31d
> 100644
> *** a/src/backend/rewrite/rewriteDefine.c
> --- b/src/backend/rewrite/rewriteDefine.c
> *************** DefineQueryRewrite(char *rulename,
> *** 356,362 ****
> */
> checkRuleResultList(query->targetList,
> RelationGetDescr(event_relation),
> ! true);
>
> /*
> * ... there must not be another ON SELECT rule already ...
> --- 357,364 ----
> */
> checkRuleResultList(query->targetList,
> RelationGetDescr(event_relation),
> ! event_relation->rd_rel->relkind !=
> ! RELKIND_MATVIEW);
>
> /*
> * ... there must not be another ON SELECT rule already ...
>
> IMO this is either flat-out wrong, or an unmaintainable crock, or both.
> So this either needs to be reverted, or refactored into two arguments
> not one, with checkRuleResultList being updated to account honestly
> and readably for whatever it's supposed to be doing here.
Will review in light of your comments.
Thanks!
--
Kevin Grittner
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company
From | Date | Subject | |
---|---|---|---|
Next Message | Jim Nasby | 2013-03-13 22:24:54 | Re: Enabling Checksums |
Previous Message | Dimitri Fontaine | 2013-03-13 21:16:18 | Re: pg_dump selectively ignores extension configuration tables |