Re: Newbie Developer Question

From: "Matthew Campbell" <mtthw(dot)cmpbll(at)gmail(dot)com>
To: "Tom Lane" <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: pgsql-novice(at)postgresql(dot)org
Subject: Re: Newbie Developer Question
Date: 2007-02-01 16:58:08
Message-ID: c2cc277f0702010858q16e6ae21qfece5981e59c06af@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-novice

Thanks so much for the help. _hash_first, and _hash_next all take the scan
object as a parameter. How do you create or get a scan object?
hashbeginscan looks like it sets up a scan and returns it, but it takes the
number of keys and the array of scan keys. Where do we get these arguments
from?

-Matt

On 2/1/07, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
>
> "Matthew Campbell" <mtthw(dot)cmpbll(at)gmail(dot)com> writes:
> > ... We've been digging through the src/backend/access/hash/
> > and we're having a hard time figuring out the correct way to walk
> through
> > items in a page. Is this what the hashbeginscan() method is for?
>
> No, hashbeginscan doesn't do much at all except initialize state. The
> interesting stuff happens during successive hashgettuple calls ---
> specifically _hash_first the first time and _hash_next on later calls.
>
> regards, tom lane
>

In response to

Responses

Browse pgsql-novice by date

  From Date Subject
Next Message ann hedley 2007-02-01 17:01:14 Re: query efficiency - Can I speed it up?
Previous Message Rob Shepherd 2007-02-01 16:57:14 Stored Procedure to return a result set