From: Dave Cramer Date: Thu, 30 Oct 2003 12:18:56 +0000 (+0000) Subject: use the result set to set the fetchsize X-Git-Tag: REL7_4_RC1~41 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=f4b4d7ce60d9e688c598ba17db53dd9e26fa3944;p=postgresql use the result set to set the fetchsize --- diff --git a/src/interfaces/jdbc/org/postgresql/test/jdbc2/CursorFetchTest.java b/src/interfaces/jdbc/org/postgresql/test/jdbc2/CursorFetchTest.java index 825760e1d4..716a2cb9b4 100644 --- a/src/interfaces/jdbc/org/postgresql/test/jdbc2/CursorFetchTest.java +++ b/src/interfaces/jdbc/org/postgresql/test/jdbc2/CursorFetchTest.java @@ -82,7 +82,7 @@ public class CursorFetchTest extends TestCase PreparedStatement stmt = con.prepareStatement("select * from test_fetch order by value"); stmt.setFetchSize(0); ResultSet rs = stmt.executeQuery(); - stmt.setFetchSize(50); // Should have no effect. + rs.setFetchSize(50); // Should have no effect. int count = 0; while (rs.next()) { @@ -108,7 +108,7 @@ public class CursorFetchTest extends TestCase PreparedStatement stmt = con.prepareStatement("select * from test_fetch order by value"); stmt.setFetchSize(25); ResultSet rs = stmt.executeQuery(); - stmt.setFetchSize(0); + rs.setFetchSize(0); int count = 0; while (rs.next()) { @@ -136,7 +136,7 @@ public class CursorFetchTest extends TestCase PreparedStatement stmt = con.prepareStatement("select * from test_fetch order by value"); stmt.setFetchSize(25); ResultSet rs = stmt.executeQuery(); - stmt.setFetchSize(50); + rs.setFetchSize(50); int count = 0; while (rs.next()) { @@ -164,7 +164,7 @@ public class CursorFetchTest extends TestCase PreparedStatement stmt = con.prepareStatement("select * from test_fetch order by value"); stmt.setFetchSize(50); ResultSet rs = stmt.executeQuery(); - stmt.setFetchSize(25); + rs.setFetchSize(25); int count = 0; while (rs.next()) {