Hi...

One question.... How many connection I must to use when I have nested
resultSet ?? Can I to use the same connection? I'am using Poolman, Tomcat 4,
jdk1.4 in WinNT... Must I close *manually* every preparedStatement and
ResultSet ?

Example....(extract from bean )

 private void myFunction()  {
  Connection con1=null, con2=null;
  try {
     con1=findConnection();
     stPlan = con1.prepareStatement(sqlPlan);
     rsPlan = stPlan.executeQuery();
     while(rsPlan.next()) {
     con2=findConexion();
     stPlanPoli  = con2.prepareStatement(sqlPlanPoli);
      ....
     rsPlanPoli = stPlanPoli.executeQuery();
     if(rsPlanPoli.next()) {
        ....
     }
     else {
        rsPlanPoli.close();   // ???
        stPlanPoli.close();   // ???
        con2.close();          // ???
     }
   }
   rsPlan.close();   // ???
   stPlan.close();   // ???
   con1.close();   // ???
  } catch (SQLException e) { ... }
 }


Thanks for advance...

Roy

===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST DIGEST".
Some relevant FAQs on JSP/Servlets can be found at:

 http://archives.java.sun.com/jsp-interest.html
 http://java.sun.com/products/jsp/faq.html
 http://www.esperanto.org.nz/jsp/jspfaq.jsp
 http://www.jguru.com/faq/index.jsp
 http://www.jspinsider.com

Reply via email to