? nodeResult.patch
Index: nodeResult.c
===================================================================
RCS file: /projects/cvsroot/pgsql/src/backend/executor/nodeResult.c,v
retrieving revision 1.29
diff -d -c -r1.29 nodeResult.c
*** nodeResult.c	31 Dec 2004 21:59:45 -0000	1.29
--- nodeResult.c	21 Apr 2005 22:14:37 -0000
***************
*** 8,22 ****
   *		Result nodes are used in queries where no relations are scanned.
   *		Examples of such queries are:
   *
!  *				retrieve (x = 1)
!  *		and
!  *				append emp (name = "mike", salary = 15000)
   *
   *		Result nodes are also used to optimise queries with constant
   *		qualifications (ie, quals that do not depend on the scanned data),
   *		such as:
   *
!  *				retrieve (emp.all) where 2 > 1
   *
   *		In this case, the plan generated is
   *
--- 8,20 ----
   *		Result nodes are used in queries where no relations are scanned.
   *		Examples of such queries are:
   *
!  *				select 1 * 2
   *
   *		Result nodes are also used to optimise queries with constant
   *		qualifications (ie, quals that do not depend on the scanned data),
   *		such as:
   *
!  *				select * from emp where 2 > 1
   *
   *		In this case, the plan generated is
   *
***************
*** 24,30 ****
   *						/
   *				   SeqScan (emp.all)
   *
!  *		At runtime, the Result node evaluates the constant qual once.
   *		If it's false, we can return an empty result set without running
   *		the controlled plan at all.  If it's true, we run the controlled
   *		plan normally and pass back the results.
--- 22,29 ----
   *						/
   *				   SeqScan (emp.all)
   *
!  *		At runtime, the Result node evaluates the constant qual once,
!  *      which is shown on an EXPLAIN as a One-Time Filter.
   *		If it's false, we can return an empty result set without running
   *		the controlled plan at all.  If it's true, we run the controlled
   *		plan normally and pass back the results.
