Re: [RFC] How about changing the default value of defaultRowFetchSize?

From: Mark Rotteveel <mark(at)lawinegevaar(dot)nl>
To: Jorge Solórzano <jorsol(at)gmail(dot)com>, Vladimir Sitnikov <sitnikov(dot)vladimir(at)gmail(dot)com>
Cc: List <pgsql-jdbc(at)postgresql(dot)org>
Subject: Re: [RFC] How about changing the default value of defaultRowFetchSize?
Date: 2016-10-20 17:55:51
Message-ID: 7c43ae3c-c12c-878d-c699-d37bf60cf6f9@lawinegevaar.nl
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-jdbc

On 20-10-2016 19:30, Jorge Solórzano wrote:
> ​So if the driver internally handle fetch size 0 == fetch size 100,
> that's what i call an hidden inconsistent behavior.
>
> Don't get me wrong, it make sense to switch ​defaultRowFetchSize to
> "100", but a call to getFetchSize() should be == 100, not 0.

And that is how it should work, however according to the JDBC
specification (or at least: that is how I read it),
Statement.setFetchSize(0) means "use driver default fetch size".

On the other hand, drivers are also free to ignore fetch size hints.

Mark
--
Mark Rotteveel

In response to

Responses

Browse pgsql-jdbc by date

  From Date Subject
Next Message Jorge Solórzano 2016-10-20 18:30:32 Re: [RFC] How about changing the default value of defaultRowFetchSize?
Previous Message Dave Cramer 2016-10-20 17:53:59 Re: [RFC] How about changing the default value of defaultRowFetchSize?