Unix Technical Forum

Adding a new node to the executor

This is a discussion on Adding a new node to the executor within the pgsql Hackers forums, part of the PostgreSQL category; --> Hey guys, I am taking my chances of posting a devel doubt on this list (couldn't find any other ...


Go Back   Unix Technical Forum > Database Server Software > PostgreSQL > pgsql Hackers

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 04-11-2008, 05:35 AM
Varun Kacholia
 
Posts: n/a
Default Adding a new node to the executor

Hey guys,
I am taking my chances of posting a devel doubt on this list (couldn't find
any other relevant list). I think I have spent too much time on
this and need a fresh pair of eyes to look in it..

So this is my situation:
1. I have added a new field to RangeTblEntry (bool tablesample).

2. I have created a new executor node (this is to do system sampling
[Ref: Query sampling thread]). In short, this new node goes over a table
block by block, skipping some blocks as required.

3. Have made the appropriate changes to the parser+planner so that the
information about a tablesample is passed from the parser to the executor.

But the RangeTblEntry received by my executor node does
not have the tablesample set, inspite of the fact that I do set it in
parse_relation.c:addRangeTableEntry().

I have made the appropriate changes to copyfuncs.c, but still in vain..
Any help would be highly appreciated. I can send a diff if someone is
interested.

Thanks
Varun

---------------------------(end of broadcast)---------------------------
TIP 5: don't forget to increase your free space map settings

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 04-11-2008, 05:35 AM
Alvaro Herrera
 
Posts: n/a
Default Re: Adding a new node to the executor

On Sat, Sep 03, 2005 at 02:43:20AM -0700, Varun Kacholia wrote:

> But the RangeTblEntry received by my executor node does
> not have the tablesample set, inspite of the fact that I do set it in
> parse_relation.c:addRangeTableEntry().
>
> I have made the appropriate changes to copyfuncs.c, but still in vain..


Did you change all the other files in src/backend/nodes? You need to
change not only copyfuncs.c, but equalfuncs, outfuncs and readfuncs as
well.

--
Alvaro Herrera -- Valdivia, Chile Architect, www.EnterpriseDB.com
"El miedo atento y previsor es la madre de la seguridad" (E. Burke)

---------------------------(end of broadcast)---------------------------
TIP 3: Have you checked our extensive FAQ?

http://www.postgresql.org/docs/faq

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3 (permalink)  
Old 04-11-2008, 05:35 AM
Bruce Momjian
 
Posts: n/a
Default Re: Adding a new node to the executor

Alvaro Herrera wrote:
> On Sat, Sep 03, 2005 at 02:43:20AM -0700, Varun Kacholia wrote:
>
> > But the RangeTblEntry received by my executor node does
> > not have the tablesample set, inspite of the fact that I do set it in
> > parse_relation.c:addRangeTableEntry().
> >
> > I have made the appropriate changes to copyfuncs.c, but still in vain..

>
> Did you change all the other files in src/backend/nodes? You need to
> change not only copyfuncs.c, but equalfuncs, outfuncs and readfuncs as
> well.


Yep. My suggestion is to pick an existing field in RangeTblEntry and
find all occurances of that, and determine if your new field has to be
added in that place.

--
Bruce Momjian | http://candle.pha.pa.us
pgman@candle.pha.pa.us | (610) 359-1001
+ If your life is a hard drive, | 13 Roberts Road
+ Christ can be your backup. | Newtown Square, Pennsylvania 19073

---------------------------(end of broadcast)---------------------------
TIP 4: Have you searched our list archives?

http://archives.postgresql.org

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump


All times are GMT. The time now is 10:14 AM.


Powered by vBulletin® Version 3.6.5
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.2.0
www.UnixAdminTalk.com