Package org.springframework.data.r2dbc
Class BadSqlGrammarException
java.lang.Object
java.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
org.springframework.core.NestedRuntimeException
org.springframework.dao.DataAccessException
org.springframework.dao.NonTransientDataAccessException
org.springframework.dao.InvalidDataAccessResourceUsageException
org.springframework.r2dbc.BadSqlGrammarException
org.springframework.data.r2dbc.BadSqlGrammarException
- All Implemented Interfaces:
Serializable
Deprecated.
Exception thrown when SQL specified is invalid. Such exceptions always have a
R2dbcException
root cause.
It would be possible to have subclasses for no such table, no such column etc. A custom
R2dbcExceptionTranslator
could create such more specific exceptions,
without affecting code using this class.
- Author:
- Mark Paluch
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionBadSqlGrammarException
(String task, String sql, R2dbcException ex) Deprecated.Creates a newBadSqlGrammarException
. -
Method Summary
Modifier and TypeMethodDescriptionDeprecated.Return the wrappedR2dbcException
.getSql()
Deprecated.Return the SQL that caused the problem.Methods inherited from class org.springframework.core.NestedRuntimeException
contains, getMessage, getMostSpecificCause, getRootCause
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
Constructor Details
-
BadSqlGrammarException
Deprecated.Creates a newBadSqlGrammarException
.- Parameters:
task
- name of current task.sql
- the offending SQL statement.ex
- the root cause.
-
-
Method Details
-
getR2dbcException
Deprecated.Return the wrappedR2dbcException
.- Overrides:
getR2dbcException
in classBadSqlGrammarException
-
getSql
Deprecated.Return the SQL that caused the problem.- Overrides:
getSql
in classBadSqlGrammarException
-
BadSqlGrammarException
instead.