Java Spring 4.2.X HibernateTemplate和SQLErrorCodeSQLExceptionTranslator

Java Spring 4.2.X HibernateTemplate和SQLErrorCodeSQLExceptionTranslator,java,spring,hibernate,exception-handling,sqlexception,Java,Spring,Hibernate,Exception Handling,Sqlexception,根据,我只能在jdbcTemplate上添加SQLErrorCodeSQLExceptionTranslator 但我使用的是不支持此异常转换器的org.springframework.orm.hibernate4.HibernateTemplatehibernate3支持此异常转换器,但不支持hibernate4 有人能建议另一种方法来处理Spring的HibernateTemplate中的SQLErrorCodes --哈努马特

根据,我只能在
jdbcTemplate
上添加
SQLErrorCodeSQLExceptionTranslator

但我使用的是不支持此异常转换器的
org.springframework.orm.hibernate4.HibernateTemplate
hibernate3
支持此异常转换器,但不支持
hibernate4

有人能建议另一种方法来处理
Spring
HibernateTemplate
中的
SQLErrorCodes

--哈努马特