-
Oct 1st, 2012, 10:36 AM
#1
Using Hibernate and jdbcTemplate together
Hi,
in the same application I have defined one datasource.
This datasource is using by hibernate (by org.springframework.orm.hibernate3.LocalSessionFac toryBean) and by jdbcTemplate (so without Hibernate). Can I do this? Can this give me problems?
For example: I have a transaction manager for hibernate (HibernateTransactionManager) and a transaction manager for jdbcTemplate (DataSourceTransactionManager) and if I use them for annotation I can't use both of them:
<tx:annotation-driven transaction-manager="txManager"/>
Any idea?
Thanks
-
Oct 2nd, 2012, 12:27 AM
#2
You don't need 2 transactionmanager you only need the HibernateTransactionManager...
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules