I use net.sourceforge.jtds.jdbc.Driver. Does it surport FetchSize?
Thank you.

-----Original Message-----
From: John Villar [mailto:[EMAIL PROTECTED]
Sent: Thursday, August 19, 2004 5:26 AM
To: Tomcat Users List
Subject: Re: Is there a way to set the size of ResultSet from MS SQL
Serve r


However, that would work only if the driver you're using uses the
FetchSize as a hint for caching records. In JDBC caching is primarily
the responsability of the Driver.

Brad McEvoy escribi�:

>something like this should do the trick
>
>...
>PreparedStatement pstmt =
>con.prepareStatement(sql,ResultSet.TYPE_FORWARD_ONLY,ResultSet.CONCUR_READ_
O
>NLY);
>pstmt.setFetchSize(100);
>ResultSet rs = pstmt.executeQuery();
>...
>
>
>-----Original Message-----
>From: QM [mailto:[EMAIL PROTECTED]
>Sent: Thursday, 19 August 2004 2:04 PM
>To: Tomcat Users List
>Subject: Re: Is there a way to set the size of ResultSet from MS SQL
>Server
>
>
>On Wed, Aug 18, 2004 at 04:50:32PM -0700, Daxin Zuo wrote:
>: I use JDBC in JSP/Java with MS SQL Server.
>: Is there a way to set the Fetch Size (set to 10, 100,..) of ResultSet (as
>: ADO CacheSize  in ASP)?
>
>This sounds like a configuration specific to your database, either with
>a custom SQL statement (a la HSQLDB) or with a JDBC URL param...
>
>Unless you mean you want to limit the results using the clause
>"LIMIT x" in your SQL.
>
>-QM
>
>
>


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to