|
7 | 7 | *
|
8 | 8 | *
|
9 | 9 | * IDENTIFICATION
|
10 |
| - * $Header: /cvsroot/pgsql/src/backend/optimizer/plan/setrefs.c,v 1.3 1997/04/24 15:54:52 vadim Exp $ |
| 10 | + * $Header: /cvsroot/pgsql/src/backend/optimizer/plan/setrefs.c,v 1.4 1997/06/12 17:26:15 vadim Exp $ |
11 | 11 | *
|
12 | 12 | *-------------------------------------------------------------------------
|
13 | 13 | */
|
@@ -690,10 +690,13 @@ replace_agg_clause(Node *clause, List *subplanTargetList)
|
690 | 690 | * This is an operator. Recursively call this routine
|
691 | 691 | * for both its left and right operands
|
692 | 692 | */
|
693 |
| -replace_agg_clause((Node*)get_leftop((Expr*)clause), |
694 |
| -subplanTargetList); |
695 |
| -replace_agg_clause((Node*)get_rightop((Expr*)clause), |
696 |
| -subplanTargetList); |
| 693 | +Node*left= (Node*)get_leftop((Expr*)clause); |
| 694 | +Node*right= (Node*)get_rightop((Expr*)clause); |
| 695 | + |
| 696 | +if (left!= (Node*)NULL ) |
| 697 | +replace_agg_clause(left,subplanTargetList); |
| 698 | +if (right!= (Node*)NULL ) |
| 699 | +replace_agg_clause(right,subplanTargetList); |
697 | 700 | }elseif (IsA(clause,Param)||IsA(clause,Const)) {
|
698 | 701 | /* do nothing! */
|
699 | 702 | }else {
|
|