public class BadSqlGrammarException extends InvalidDataAccessResourceUsageException
java.sql.SQLException root cause.
It would be possible to have subclasses for no such table, no such column etc. A custom SQLExceptionTranslator could create such more specific exceptions, without affecting code using this class.
InvalidResultSetAccessException,
Serialized Form| Modifier and Type | Field and Description |
|---|---|
private java.lang.String |
sql |
| Constructor and Description |
|---|
BadSqlGrammarException(java.lang.String task,
java.lang.String sql,
java.sql.SQLException ex)
Constructor for BadSqlGrammarException.
|
| Modifier and Type | Method and Description |
|---|---|
java.lang.String |
getSql()
Return the SQL that caused the problem.
|
java.sql.SQLException |
getSQLException()
Return the wrapped SQLException.
|
contains, getMessage, getMostSpecificCause, getRootCause