From: | "Tsunakawa, Takayuki" <tsunakawa(dot)takay(at)jp(dot)fujitsu(dot)com> |
---|---|
To: | 'Dave Cramer' <pg(at)fastcrypt(dot)com> |
Cc: | Jorge Solórzano <jorsol(at)gmail(dot)com>, "Vitalii Tymchyshyn" <vit(at)tym(dot)im>, Mark Rotteveel <mark(at)lawinegevaar(dot)nl>, List <pgsql-jdbc(at)postgresql(dot)org>, Vladimir Sitnikov <sitnikov(dot)vladimir(at)gmail(dot)com> |
Subject: | Re: [RFC] How about changing the default value of defaultRowFetchSize? |
Date: | 2016-10-25 03:15:01 |
Message-ID: | 0A3221C70F24FB45833433255569204D1F6360B5@G01JPEXMBYT05 |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-jdbc |
From: davecramer(at)gmail(dot)com [mailto:davecramer(at)gmail(dot)com] On Behalf Of
> Dave Cramer
> This is what I take issue with. It should return 0 which means that it has
> not been set. What use is it to the user ?
I'm sorry to repeat myself. According to the API doc, the use of getFetchSize() is to retrieve the number of result set rows, not the hint value. So, I thought 0 was not appropriate because 0 is only a valid hint value passed to setFetchSize(). Which sentence in what document does your returning 0 follow?
http://docs.oracle.com/javase/7/docs/api/java/sql/Statement.html
Retrieves the number of result set rows that is the default fetch size for ResultSet objects generated from this Statement object. If this Statement object has not set a fetch size by calling the method setFetchSize, the return value is implementation-specific.
Returns:the default fetch size for result sets generated from this Statement object
> 1000 has been determined to be optimal. Both Vladimir and I have done
> performance testing on this. Also it won't matter to the user, since if
> they only have 100 rows they will only get 100 rows back anyway. 1000 rows
> should be able to fit into any reasonable client machines memory
OK, agreed.
Regards
Takayuki Tsunakawa
From | Date | Subject | |
---|---|---|---|
Next Message | Amit Kapila | 2016-10-25 08:15:52 | Re: Patch: Implement failover on libpq connect level. |
Previous Message | Alvaro Herrera | 2016-10-24 20:40:14 | Re: Patch: Implement failover on libpq connect level. |