Skip site navigation (1) Skip section navigation (2)

Re: [HACKERS] Rule plan size for views?

From: "Thomas G(dot) Lockhart" <lockhart(at)alumni(dot)caltech(dot)edu>
To: Bruce Momjian <maillist(at)candle(dot)pha(dot)pa(dot)us>
Cc: jwieck(at)debis(dot)com, darrenk(at)insightdist(dot)com, pgsql-hackers(at)postgresql(dot)org
Subject: Re: [HACKERS] Rule plan size for views?
Date: 1998-03-03 05:49:56
Message-ID: 34FB9A04.2EE8F593@alumni.caltech.edu (view raw or flat)
Thread:
Lists: pgsql-hackers
> I don't see any of these affecting the rewrite system.  They should
> already have been in the code.  Were they not?

I recall adding code to print the nodes of a create index statement, and the nodes of a
table create statement. I don't quite remember which other ones, but everything listed
below is new since v6.2.1.

> > > _outCreateStmt(StringInfo str, CreateStmt *node)
> > >       _outNode(str, node->tableElts);
> > >       _outNode(str, node->inhRelnames);
> > >       _outNode(str, node->constraints);
> > > _outIndexStmt(StringInfo str, IndexStmt *node)
> > >       _outNode(str, node->indexParams);
> > >       _outNode(str, node->withClause);
> > >       _outNode(str, node->whereClause);
> > >       _outNode(str, node->rangetable);
> > > _outColumnDef(StringInfo str, ColumnDef *node)
> > >       _outNode(str, node->typename);
> > >       _outNode(str, node->constraints);
> > > _outTypeName(StringInfo str, TypeName *node)
> > >       _outNode(str, node->arrayBounds);
> > > _outIndexElem(StringInfo str, IndexElem *node)
> > >       _outNode(str, node->args);
> > >       _outNode(str, node->tname);
> > >                       case T_CreateStmt:
> > >                               _outNode(str, node->utilityStmt);
> > >                       case T_IndexStmt:
> > >                               _outNode(str, node->utilityStmt);
> > >                       case T_NotifyStmt:
> > >       _outNode(str, node->sortClause);
> > >       _outNode(str, node->groupClause);
> > >       _outNode(str, node->havingQual);
> > >       _outNode(str, node->unionClause);
> > > _outSortClause(StringInfo str, SortClause *node)
> > >       _outNode(str, node->resdom);
> > > _outGroupClause(StringInfo str, GroupClause *node)
> > >       _outNode(str, node->entry);
> > >       sprintf(buf, " :size %d ", node->plan_size);
> > >       sprintf(buf, " :width %d ", node->plan_width);
> > >       _outIntList(str, node->extParam);
> > >       _outIntList(str, node->locParam);
> > >       _outNode(str, node->initPlan);
> > >       _outNode(str, node->unionrts);
> > > _outSubPlan(StringInfo str, SubPlan *node)
> > >       _outNode(str, node->plan);
> > >       sprintf(buf, " :planid %u ", node->plan_id);
> > >       _outNode(str, node->rtable);
> > >       _outIntList(str, node->setParam);
> > >       _outIntList(str, node->parParam);
> > >       _outNode(str, node->sublink);
> > >       _outNode(str, node->aggs);
> > >       appendStringInfo(str, node->fj_initialized ? "true" : "false");
> > >       sprintf(buf, " :nNodes %d ", node->fj_nNodes);
> > >               appendStringInfo(str, (node->fj_alwaysDone[i]) ? "true" : "false");
> > >               case SUBPLAN_EXPR:
> > >       _outNode(str, node->target);
> > > _outSubLink(StringInfo str, SubLink *node)
> > >       _outNode(str, node->lefthand);
> > >       _outNode(str, node->oper);
> > >       _outNode(str, node->subselect);
> > >       _outNode(str, node->expr);
> > > _outAExpr(StringInfo str, A_Expr *node)
> > >       _outNode(str, node->lexpr);
> > >       _outNode(str, node->rexpr);
> > > _outIdent(StringInfo str, Ident *node)
> > > _outAConst(StringInfo str, A_Const *node)
> > >       _outValue(str, &(node->val));
> > >                       case T_CreateStmt:
> > >                               _outCreateStmt(str, obj);
> > >                       case T_IndexStmt:
> > >                               _outIndexStmt(str, obj);
> > >                       case T_ColumnDef:
> > >                               _outColumnDef(str, obj);
> > >                       case T_TypeName:
> > >                               _outTypeName(str, obj);
> > >                       case T_IndexElem:
> > >                               _outIndexElem(str, obj);
> > >                       case T_SortClause:
> > >                               _outSortClause(str, obj);
> > >                       case T_GroupClause:
> > >                               _outGroupClause(str, obj);
> > >                       case T_SubPlan:
> > >                               _outSubPlan(str, obj);
> > >                       case T_SubLink:
> > >                               _outSubLink(str, obj);
> > >                       case T_A_Expr:
> > >                               _outAExpr(str, obj);
> > >                       case T_Ident:
> > >                               _outIdent(str, obj);
> > >                       case T_A_Const:
> > >                               _outAConst(str, obj);




In response to

Responses

pgsql-hackers by date

Next:From: Bruce MomjianDate: 1998-03-03 05:58:38
Subject: Re: [HACKERS] Rule plan size for views?
Previous:From: Bruce MomjianDate: 1998-03-03 04:10:31
Subject: Re: [HACKERS] doc troubles.

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group