| java.lang.Object net.sourceforge.jtds.jdbc.SQLDiagnostic
SQLDiagnostic | class SQLDiagnostic (Code) | | Helper class for handling SQL warnings and errors. Assigns SQL state values
in accordance to the native error number returned by the database server.
author: Alin Sinpalean author: Mike Hutchinson version: $Id: SQLDiagnostic.java,v 1.12 2007/08/05 20:17:54 bheineman Exp $ |
Constructor Summary | |
| SQLDiagnostic(int serverType) Create an SQL message for a specific server type. |
SQLDiagnostic | SQLDiagnostic(int serverType)(Code) | | Create an SQL message for a specific server type.
Parameters: serverType - either Driver.SQLSERVER or Driver.SYBASE |
addDiagnostic | void addDiagnostic(int number, int state, int serverity, String message, String server, String procName, int line)(Code) | | Create a dianostic SQLException or SQLWarning.
Parameters: number - SQL Server error number. Parameters: state - SQL Server state code. Parameters: serverity - SQL Server serverity > 10 = error. Parameters: message - SQL Server error message text. Parameters: server - SQL Server name. Parameters: procName - SQL Server stored procedure name. Parameters: line - SQL Server error line number in SQL source. |
checkErrors | void checkErrors() throws SQLException(Code) | | Check the exception chain for errors and throw any found
as an SQLException.
throws: SQLException - |
clearWarnings | void clearWarnings()(Code) | | Clear the warning chain.
|
getWarnings | SQLWarning getWarnings()(Code) | | Return the warning chain.
The warning chain head as a SQLWarning . |
|
|