//Statement stmt1 = conn.createStatement(ResultSet.TYPE_SCROLL_INSENSITIVE,ResultSet.CONCUR_UPDATABLE);
ResultSet rs = stmt1.executeQuery(reportQuery1);
ResultSet rs2 = stmt1.executeQuery(reportQuery2);
ResultSet rs3 = stmt1.executeQuery(reportQuery3);
if the 'rs' is empty then it is giving me null pointer exception in the first while loop.My understanding is that even if the resultset(rs) is empty it should not give me null pointer exception. Please advice.
By default, only one ResultSet object per Statement object can be open at the same time. Therefore, if the reading of one ResultSet object is interleaved with the reading of another, each must have been generated by different Statement objects. All execution methods in the Statement interface implicitly close a statment's current ResultSet object if an open one exists.