JBoss Community

Re: JBoss autocommit problem

created by vishal kalra in JNDI and Naming - View the full discussion

All,

 

Sorry for reviving this old thread but I am getting exactly same issue

 

" java.sql.SQLException: You cannot rollback with autocommit set!"

 

I tried to <no-tx-datasource> instead of <local-tx-datasource> in the -ds.xml file , I am deploying this on jboss 4.3.0.GA. My application uses hibernate and in one of the HibernateSessionWrapperclass I have the following code

 

if (this.session.connection().getAutoCommit()) {

                                                  this.session.connection().setAutoCommit(false);

                                        }

 

I tried commenting this too without success. Please help !!! m clueless here...

Reply to this message by going to Community

Start a new discussion in JNDI and Naming at Community