Re: ECPG FETCH readahead - Mailing list pgsql-hackers

From Boszormenyi Zoltan
Subject Re: ECPG FETCH readahead
Date
Msg-id 4F745394.40007@cybertec.at
Whole thread Raw
In response to Re: ECPG FETCH readahead  (Boszormenyi Zoltan <zb@cybertec.at>)
List pgsql-hackers
2012-03-29 12:59 keltezéssel, Boszormenyi Zoltan írta:
> 2012-03-29 02:43 keltezéssel, Noah Misch írta:
>> On Sat, Mar 24, 2012 at 10:49:07AM +0100, Boszormenyi Zoltan wrote:
>>> +    the window size may be modified by setting the<literal>ECPGFETCHSZ</literal>
>>> +    environment variable to a different value.
>> I had in mind that DECLARE statements adorned with READAHEAD syntax would
>> always behave precisely as written, independent of ECPGFETCHSZ or "ecpg -R".
>> Unadorned DECLARE statements would use ECPGFETCHSZ if set, then the value
>> passed to "ecpg -R" if provided, and finally a value of 1 (no readahead) in
>> the absence of both ECPGFETCHSZ and "ecpg -R".  Did you do it differently for
>> a particular reason?  I don't particularly object to what you've implemented,
>> but I'd be curious to hear your thinking.
>
> What I had in mind was:
>
> NO READAHEAD == READAHEAD 0. This will translate into 1 tuple sized
> readahead window that cannot be modified by ECPGFETCHSZ.

After the core patch, this is not totally true yet. The "NO READAHEAD"
cursors don't go through the new cursor functions at all. But cursor.c
is prepared for the second patch that makes all cursors use the caching code.

Best regards,
Zoltán Böszörményi

--
----------------------------------
Zoltán Böszörményi
Cybertec Schönig&  Schönig GmbH
Gröhrmühlgasse 26
A-2700 Wiener Neustadt, Austria
Web: http://www.postgresql-support.de     http://www.postgresql.at/



pgsql-hackers by date:

Previous
From: "Kevin Grittner"
Date:
Subject: Re: Finer Extension dependencies
Next
From: Dimitri Fontaine
Date:
Subject: Re: Command Triggers patch v18