728x90 반응형 SMALL mybatis rollback1 commit / rollback - MyBatis public void updateSample(testDto param) throws Exception{ SqlSession tmpSession = sqlSessionFactory.openSession(); try{ // Delete all tmpSession.delete("deleteSample", param); // Insert New Data tmpSession.insert("insertSample", param); tmpSession.commit(); }catch(Exception e){ tmpSession.rollback(); logger.error("TestDao updateSample e : "+e.getMessage()); throw e; }finally{ if(tmpSes.. 2013. 12. 24. 이전 1 다음 728x90 반응형 LIST