SQLExceptions
and Spring's data access strategy-agnostic DataAccessException
hierarchy.
Implementations can be generic (for example, using
SQLState codes for JDBC) or wholly
proprietary (for example, using Oracle error codes) for greater precision.
org.springframework.dao.DataAccessException
| Modifier and Type | Method and Description |
|---|---|
| public DataAccessException | Returns: the DataAccessException wrapping theSQLException,
or null if no specific translation could be appliedreadable text describing the task being attempted task, String the SQL query or update that caused the problem (if known) sql, SQLException the offending ex)SQLExceptionTranslate the given |
| translate | back to summary |
|---|---|
| public DataAccessException translate(String task, String sql, SQLException ex) Translate the given The returned DataAccessException is supposed to contain the original
| |