public int onNativeUpdate ( String query , Map < Parameter , Object > parameterMap ) { s = getStatelessSession ( ) ; Query q = s . createSQLQuery ( query ) ; setParameters ( parameterMap , q ) ; // Transaction tx = s.getTransaction() == null ? s.beginTransaction(): // s.getTransaction(); // tx.begin(); int i = q . executeUpdate ( ) ; // tx.commit(); return i ; }
On native update .