I have tried out the following in my local machine using jdbc/mysql:
- step 1: conn = getNewConnection
- step 2: stmt1 = "new statement" using connection 'conn'
- step 3: stmt2 = "new statement" using the same connection 'conn'
- step 4: resultSet1 = execute stmt1
- step 5: resultSet2 = execute stmt2
- step 6: operating on both resultset 1 and 2
- step 7: proper closing of all resources
worked fine in my machine. Can I be sure of this behaviour always (Mysql/Postgres with JDBC )? Will there be any issue?