public void addVehicleDate(String sql) { Session session = getHibernateTemplate().getSessionFactory() .getCurrentSession(); Connection con = session.connection(); PreparedStatement prestmt = null; try { prestmt = con.prepareStatement(sql); prestmt.executeUpdate(sql); prestmt.close(); con.close(); } catch (SQLException e) { e.printStackTrace(); } session.close(); } 向Oracle中一次添加多条记录的写法 insert into 表名(字段1,字段2) select '一','二' from dual union all select '三','四' from dual union all select '五','六' from dual union all select '七','八' from dual union all select '九','十' from dual