Esempio n. 1
0
 long dCountRec(java.sql.Statement stat, String table, String sWhere) {
   long lNumRecs = 0;
   try {
     java.sql.ResultSet rs =
         stat.executeQuery("select count(*) from " + table + " where " + sWhere);
     if (rs != null && rs.next()) {
       lNumRecs = rs.getLong(1);
     }
     rs.close();
   } catch (Exception e) {
   }
   ;
   return lNumRecs;
 }
Esempio n. 2
0
 java.sql.ResultSet openrs(java.sql.Statement stat, String sql) throws java.sql.SQLException {
   java.sql.ResultSet rs = stat.executeQuery(sql);
   return (rs);
 }