|
|
|
|
@ -7,7 +7,7 @@ |
|
|
|
|
* |
|
|
|
|
* |
|
|
|
|
* IDENTIFICATION |
|
|
|
|
* $Header: /cvsroot/pgsql/src/backend/optimizer/plan/setrefs.c,v 1.42 1999/04/26 00:37:46 tgl Exp $ |
|
|
|
|
* $Header: /cvsroot/pgsql/src/backend/optimizer/plan/setrefs.c,v 1.43 1999/04/29 00:20:27 tgl Exp $ |
|
|
|
|
* |
|
|
|
|
*------------------------------------------------------------------------- |
|
|
|
|
*/ |
|
|
|
|
@ -747,6 +747,9 @@ replace_agg_clause(Node *clause, List *subplanTargetList) |
|
|
|
|
List *t; |
|
|
|
|
List *agg_list = NIL; |
|
|
|
|
|
|
|
|
|
if (clause == NULL) |
|
|
|
|
return NIL; |
|
|
|
|
|
|
|
|
|
if (IsA(clause, Var)) |
|
|
|
|
{ |
|
|
|
|
TargetEntry *subplanVar; |
|
|
|
|
@ -864,6 +867,9 @@ del_agg_clause(Node *clause) |
|
|
|
|
{ |
|
|
|
|
List *t; |
|
|
|
|
|
|
|
|
|
if (clause == NULL) |
|
|
|
|
return clause; |
|
|
|
|
|
|
|
|
|
if (IsA(clause, Var)) |
|
|
|
|
return clause; |
|
|
|
|
else if (is_funcclause(clause)) |
|
|
|
|
@ -942,6 +948,9 @@ check_having_qual_for_vars(Node *clause, List *targetlist_so_far) |
|
|
|
|
{ |
|
|
|
|
List *t; |
|
|
|
|
|
|
|
|
|
if (clause == NULL) |
|
|
|
|
return targetlist_so_far; |
|
|
|
|
|
|
|
|
|
if (IsA(clause, Var)) |
|
|
|
|
{ |
|
|
|
|
RelOptInfo tmp_rel; |
|
|
|
|
@ -1035,6 +1044,9 @@ check_having_for_ungrouped_vars(Node *clause, List *groupClause) |
|
|
|
|
{ |
|
|
|
|
List *t; |
|
|
|
|
|
|
|
|
|
if (clause == NULL) |
|
|
|
|
return; |
|
|
|
|
|
|
|
|
|
if (IsA(clause, Var)) |
|
|
|
|
{ |
|
|
|
|
/* Ignore vars elsewhere in the having clause, since the
|
|
|
|
|
|