Marko Tiikkaja <marko.tiikkaja@cs.helsinki.fi> wrote:
> Here's an updated patch. Only changes from the previous patch are
> fixing the above issue and a regression test for it.
A brief report for of the patch:
* The patch has the following error cases, and also have one regression test for each case.
- DML WITH is not allowed in a cursor declaration- DML WITH is not allowed in a view definition- DML WITH without
RETURNINGis only allowed inside an unreferenced CTE- DML WITH is only allowed at the top level- Recursive DML WITH
statementsare not supported ^-- might be better if "DML WITH cannot have the self-reference" or so?
- Conditional DO INSTEAD rules are not supported in DML WITH statements- DO ALSO rules are not supported in DML WITH
statements-Multi-statement DO INSTEAD rules are not supported in DML WITH statements- DO INSTEAD NOTHING rules are not
supportedin DML WITH statements
* In the regression tests, almost all of them don't have ORDER BY clause. They just work, but we might need ORDER BY to
getrobust output. What did we do in other regression tests?
* I feel odd the following paragraph in the docs, but should be checked by native English speakers.
*** a/doc/src/sgml/ref/create_rule.sgml
--- b/doc/src/sgml/ref/create_rule.sgml
***************
*** 222,227 **** CREATE [ OR REPLACE ] RULE <replaceable class="parameter">name</replaceable> AS
--- 222,234 ---- </para> <para>
+ In an <literal>INSERT</literal>, <literal>UPDATE</literal> or
+ <literal>DELETE</literal> query within a <literal>WITH</literal> clause,
+ only unconditional, single-statement <literal>INSTEAD</literal> rules are ^-- and? which
commais the sentence separator?
+ implemented. ^-- might be "available" rather than "implemented"?
+ </para>
Regards,
---
Takahiro Itagaki
NTT Open Source Software Center