public class JDBCException extends HibernateException
SQLException.  Indicates that an exception occurred during a JDBC call.SQLException, 
Serialized Form| Constructor and Description | 
|---|
JDBCException(String message,
             SQLException cause)
Constructs a JDBCException using the given information. 
 | 
JDBCException(String message,
             SQLException cause,
             String sql)
Constructs a JDBCException using the given information. 
 | 
| Modifier and Type | Method and Description | 
|---|---|
int | 
getErrorCode()
Get the vendor specific error code from the underlying  
SQLException. | 
String | 
getSQL()
Get the actual SQL statement being executed when the exception occurred. 
 | 
SQLException | 
getSQLException()
Get the underlying  
SQLException. | 
String | 
getSQLState()
Get the X/Open or ANSI SQL SQLState error code from the underlying  
SQLException. | 
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toStringpublic JDBCException(String message, SQLException cause)
message - The message explaining the exception conditioncause - The underlying causepublic JDBCException(String message, SQLException cause, String sql)
message - The message explaining the exception conditioncause - The underlying causesql - The sql being executed when the exception occurredpublic String getSQLState()
SQLException.SQLException.getSQLState()public int getErrorCode()
SQLException.SQLException.getErrorCode()public SQLException getSQLException()
SQLException.public String getSQL()
Copyright © 2001-2015 Red Hat, Inc. All Rights Reserved.