tim lok

Greenhorn
+ Follow
since Mar 19, 2001
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by tim lok

Does anybody list out the limitations of JReport? Thanks.
------------------
To resolve your problem, the simplest way is to close any resultset object.
Try the following:
resultSet.getStatement().close();

Originally posted by padmanabh dongre:

hi
I am having this problem of getting an error message max cursors open. i have a couple of doubts in this :
1. are database connection (java.sql.Connection class) they also called cursors. can this error come if i dont close my connections properly ??
2. how many connections will be opened by following type of code ? can this be the reason for getting the error max cursor open?
void meth1()
{

Connection conn = class.forName(......);
for(i=0;i<=30;i++)
meth2(conn);
conn.close();
}
void meth2(Connection conn)
{
// No statement here for closing the connection.
}

Plz help. its urgent
Thanx
Padmanabh


If you use Oracle, you can close the resultset as well.
resultSet.getStatement().close();
In doing so, you should be able to prevent any unclosed cursor.

Originally posted by Shubhashis Dasgupta:
Hi all,
I have a question on JDBC connection pools. I have created a connection pool in WebLogic Server and using it from my application. As we know, in case of hand-coded connection pools we release the connection to the pool, once it is used. How do we release a connection in case of server specific connection pool. I am getting the connection object from a datasource related to the connection pool that I have created in WLS. I do not know how to release it.
Shubhashis


Originally posted by Nair Anoop:
Hi,
I am performing the following operations:
1. Open a connection and execute a query statement
2. I get a resultSet which I wish to update using the same statement and conn. object. It gives me "ResultSet " closed error.
3. If I use a second statement object, it tells me that the conn. is busy with results of another statement.
Please help me solve the above problem.


The myConn object should be closed outside the while loop.