borland Packages Class Hierarchy dx.sql.dataset Package
java.lang.Object +----com.borland.dx.sql.dataset.ResolveError
Variables Properties Methods
Implements Serializable
This class provides information about a specific row that could not be resolved.
The ResolutionManager
that is invoked by calling DataSet.saveChanges()
or Database.saveChanges()
will log errors in an error DataSet
for all rows that meet the following criteria:
StorageDataSets
being resolved has the StorageDataSet.maxResolveErrors
property set to a value greater than 0. If this property is set to -1, all errors will be logged.
SQLException
) was encountered for the row as it was being inserted, deleted or updated.
At the end of the resolution process that is not aborted, a ResolutionException
with an error code of ResolutionException.RESOLVE_PARTIAL
will be thrown after an attempt to resolve all rows is made and the successfully resolved rows are commited. If the StorageDataSet.MaxResolveErrors
limit is reached, a ResolutionException
with an error code of ResolutionException.RESOLVE_FAILED
will be thrown.
The ResolutionException.getErrorDataSets()
method can be used to get all the errors for which ErrorResponse.ignore()
was called. This method returns an array of StorageDataSets
. There is one StorageDataSet
for every DataSet
that participated in the resolution. The order of the StorageDataSets
in the error StorageDataSet
array corresponds to the order of the DataSets
that were passed into the Database.saveChanges()
method.
If there are multiple StorageDataSets
being resolved and a particular DataSet
did not encounter any errors, its index in the error StorageDataSet
array will be null.
The error StorageDataSet
array has the same columns as its corresponding DataSet
that was resolved plus one extra RESOLVE_ERROR
column. The RESOLVE_ERROR
column is of type Variant.OBJECT
and is appended as the last column in the error StorageDataSet
. The RESOLVE_ERROR
column contains an instance of the ResolveError
class.
StorageDataSet.maxResolveErrors
, ResolutionException.RESOLVE_PARTIAL
, ResolutionException.RESOLVE_FAILED
public int categoryCurrently not used for JDBC related errors.
public int codeCurrently set to
ex.getErrorCode()
if the exception is extended from DataSetException
.
If the error was caused by a java.sql.SQLException
, this is the int value returned from calling SQLException.getErrorCode()
.
public String contextIf the is error caused by a
java.sql.SQLException
, this is the String
value returned from calling SQLException.getMessage()
, concatenated with the return value of SQLException.getSQLState
.
public Exception exIf not null, the
Exception
that caused this error.
public long internalRow
DataSet
internalRow
that encountered the error. internalRow
is a unique identifier for the row.
public String messageThe error message for the error. Usually the same as
ex.getMessage()
.
public int responseSet to
ErrorResponse.ABORT
if the error terminated the resolution transaction.
Set to ErrorResponse.IGNORE
if the error was ignored.
public int row
DataSet
row that encountered the error. In the case of detail DataSets
, this is not always unique since a single detail DataSet
can have multiple groups of records with identical row values.