Commit 9981b0f9 authored by Jan Wieck's avatar Jan Wieck

Fire rule actions ON INSERT after original statement (if not INSTEAD).

Jan
parent 852a26f7
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
* Portions Copyright (c) 1994, Regents of the University of California * Portions Copyright (c) 1994, Regents of the University of California
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/rewrite/rewriteHandler.c,v 1.95 2001/06/13 18:56:30 tgl Exp $ * $Header: /cvsroot/pgsql/src/backend/rewrite/rewriteHandler.c,v 1.96 2001/07/06 13:40:47 wieck Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
...@@ -860,6 +860,9 @@ deepRewriteQuery(Query *parsetree) ...@@ -860,6 +860,9 @@ deepRewriteQuery(Query *parsetree)
* the rule actions cannot find them. * the rule actions cannot find them.
*/ */
if (!instead) if (!instead)
if (parsetree->commandType == CMD_INSERT)
rewritten = lcons(parsetree, rewritten);
else
rewritten = lappend(rewritten, parsetree); rewritten = lappend(rewritten, parsetree);
return rewritten; return rewritten;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment