Exemple #1
0
 public void DbInsertLoginCar(List<LoginCar> list) throws SQLException {
   Iterator<LoginCar> iter = list.iterator();
   LoginCar lc = new LoginCar();
   while (iter.hasNext()) {
     lc = iter.next();
     String sql = "insert into CarInfo values(" + lc.getLoginId() + "," + lc.getCarId() + ");";
     state.executeUpdate(sql);
   }
 }
Exemple #2
0
 public int DbInsertLoginCar(LoginCar lc) throws SQLException {
   String sql = "insert into CarInfo values(" + lc.getLoginId() + "," + lc.getCarId() + ");";
   return state.executeUpdate(sql);
 }