diff options
author | Bruce Momjian | 1998-09-01 04:40:42 +0000 |
---|---|---|
committer | Bruce Momjian | 1998-09-01 04:40:42 +0000 |
commit | fa1a8d6a97068295fe30ac646aec7493a6305bc2 (patch) | |
tree | 645f7cef3c78fbab4d6d7bbc7c9a61ad2893d273 /src/backend/optimizer/plan/subselect.c | |
parent | af74855a608da4cd7ef88ceb2241ec1c75537f39 (diff) |
OK, folks, here is the pgindent output.
Diffstat (limited to 'src/backend/optimizer/plan/subselect.c')
-rw-r--r-- | src/backend/optimizer/plan/subselect.c | 25 |
1 files changed, 14 insertions, 11 deletions
diff --git a/src/backend/optimizer/plan/subselect.c b/src/backend/optimizer/plan/subselect.c index 61d0df57afa..a1b4cd22cce 100644 --- a/src/backend/optimizer/plan/subselect.c +++ b/src/backend/optimizer/plan/subselect.c @@ -405,20 +405,23 @@ SS_process_sublinks(Node *expr) SS_process_sublinks((Node *) ((Expr *) expr)->args); else if (IsA(expr, SubLink))/* got it! */ { - /* Hack to make sure expr->oper->args points to the same VAR node - * as expr->lefthand does. Needed for subselects in the havingQual - * when used on views. - * Otherwise aggregate functions will fail later on (at execution - * time!) Reason: The rewite System makes several copies of the - * VAR nodes and in this case it should not do so :-( */ - if(((SubLink *) expr)->lefthand != NULL) + + /* + * Hack to make sure expr->oper->args points to the same VAR node + * as expr->lefthand does. Needed for subselects in the havingQual + * when used on views. Otherwise aggregate functions will fail + * later on (at execution time!) Reason: The rewite System makes + * several copies of the VAR nodes and in this case it should not + * do so :-( + */ + if (((SubLink *) expr)->lefthand != NULL) { - lfirst(((Expr *) lfirst(((SubLink *)expr)->oper))->args) = - lfirst(((SubLink *)expr)->lefthand); + lfirst(((Expr *) lfirst(((SubLink *) expr)->oper))->args) = + lfirst(((SubLink *) expr)->lefthand); } - expr = _make_subplan((SubLink *) expr); + expr = _make_subplan((SubLink *) expr); } - + return expr; } |