From: | Neil Conway <neilc(at)samurai(dot)com> |
---|---|
To: | pgsql-hackers <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: read-only planner input |
Date: | 2005-03-18 05:38:35 |
Message-ID: | 423A695B.9010508@samurai.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Neil Conway wrote:
> (b) should be pretty easy to solve; we can create a per-Query PlanState
> struct that contains this information, as well as holding a pointer to
> the Query (and perhaps the in-construct Plan tree).
I just noticed that there is a `PlanState' node in the executor, of all
places. I'm thinking of using `QueryState' instead -- this parallels the
usage of PlanState in the executor, to some degree (PlanState holds some
of the state of the executor as it examines a Plan; QueryState holds
some of the state of the planner as it examines a Query). I also
considered `PlannerState', but that doesn't seem best, as there can be
multiple instances of this struct in existence for a single invocation
of planner() (due to subqueries).
I also created a new header file, `plan_internals.h' for the declaration
of this struct, and moved a few planner-internal declarations from
planner.h to plan_internals.h -- I think it would be best to only define
external interfaces in planner.h
-Neil
From | Date | Subject | |
---|---|---|---|
Next Message | Qingqing Zhou | 2005-03-18 05:39:22 | Re: read-only planner input |
Previous Message | Tom Lane | 2005-03-18 05:29:24 | Re: Query crashes/hangs server |