User`s guide

3 Working with Data Sources
3-8
Vendor Error Message Probable Causes Resolution
error happens
after executing
fetch. This error
happens only with
the command line.
PostgreSQL Java exception
occurred:
java.lang.OutOfMemoryError:
Java heap space
The JDBC driver
caches results in the
memory. There is
not enough memory
in the Java heap
to store the large
amount of data
fetched from your
database. This
error happens after
executing exec but
before executing
fetch. This error
happens either with
Database Explorer or
the command line.
Write custom code.
Write the code for
connecting to your
database via the
command line. Then
write the following.
set(conn,'AutoCommit','off');
h = conn.Handle;
stmt =
h.createStatement();
stmt.setFetchSize(50);
rs =
stmt.executeQuery(java.lang.String('select
* from
largeData where
productnumber <=
3000000'));
Modify the previous
statement to include
your SQL query
instead.
Then process the
resultset object rs in
batches.