Re: Expression Evaluator used for creating the plan tree / stmt ?

From: Vaibhav Kaushal <vaibhavkaushal123(at)gmail(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Alvaro Herrera <alvherre(at)commandprompt(dot)com>, pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Expression Evaluator used for creating the plan tree / stmt ?
Date: 2011-05-25 16:34:08
Message-ID: BANLkTin_mXR3ECyPqUVosu7=D8cqO=oBQg@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

But somehow the execevalvar is being called. When i changed the logic of its
working to use slot_getattr instead of cute_datum_array for the first run /
call, everything just worked!

This would indicate surely that the function does get called at least once
before being called by executor for qual check. This is what got me confused
- where does the function get called? Gdb trace says its first call comes
through ExecutePlan but results say something else. Moreover, gdb still
confuses me. Is there some gui to gdb? :(

The only thing i am trying to make sure that ExecEvalVar gets the values
from cute_datum_array only when called durin a scan, no way before it. May
be there could be another way. I think i have to rethink about this.
--
Sent from my Android
On 25 May 2011 20:34, "Tom Lane" <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
> Alvaro Herrera <alvherre(at)commandprompt(dot)com> writes:
>> Excerpts from Vaibhav Kaushal's message of mié may 25 05:52:32 -0400
2011:
>>> If the above is confusing, I just want to ask: "Is expression evaluator,
>>> even in part responsible for {PLANNEDSTMT creation?"
>
>> Yeah, as far as I understood Tom's talk, the expr evaluator is used to
>> reduce some expressions to constants and such.
>
> The planner would never call it with an expression containing a Var,
> though.
>
> regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Vaibhav Kaushal 2011-05-25 16:36:38 Re: Expression Evaluator used for creating the plan tree / stmt ?
Previous Message Robert Haas 2011-05-25 16:27:38 Re: Proposal: Another attempt at vacuum improvements