Class OracleSQLExceptionTranslater

All Implemented Interfaces:

public class OracleSQLExceptionTranslater
extends java.lang.Object
implements SQLExceptionTranslater

Implementation of SQLExceptionTranslator that uses Oracle vendor code, as included in the ORA-nnn methods. More precise than SQLState implementation, but Oracle-specific. The JdbcTemplate class enables error handling to be parameterized without making application's dependent on a particular RDBMS.
****TODO: this class should handle a much wider range of Oracle error codes. This can easily be done by adding additional values to the switch.

$Id:,v 1.1 2003/05/27 18:05:05 jhoeller Exp $
Rod Johnson

Constructor Summary
Method Summary
 DataAccessException translate(java.lang.String task, java.lang.String sql, java.sql.SQLException sqlex)
          Translate the given SQL exception into a generic data access exception.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Constructor Detail


public OracleSQLExceptionTranslater()
Method Detail


public DataAccessException translate(java.lang.String task,
                                     java.lang.String sql,
                                     java.sql.SQLException sqlex)
Description copied from interface: SQLExceptionTranslater
Translate the given SQL exception into a generic data access exception.
Specified by:
translate in interface SQLExceptionTranslater
See Also:
SQLExceptionTranslater.translate(java.lang.String, java.lang.String, java.sql.SQLException)

Rod Johnson and Spring contributors 2001-2003.