Class SqlBatchException

All Implemented Interfaces:
Serializable, TraceableException

public class SqlBatchException extends SqlException
Subclass of SqlException is thrown when an error occurs during a batch update operation. In addition to the information provided by SqlException, SqlBatchException provides the update counts for all commands that were executed successfully during the batch update, that is, all commands that were executed before the error occurred. The order of elements in the array of update counts corresponds to the order in which these commands were added to the batch.
See Also:
  • Constructor Details

    • SqlBatchException

      public SqlBatchException(UUID traceId, int code, long[] updCntrs, String message, @Nullable @Nullable Throwable cause)
      Creates a grid exception with the given throwable as a cause and source of error message.
      Parameters:
      traceId - Unique identifier of the exception.
      code - Full error code.
      updCntrs - Array that describes the outcome of a batch execution.
      message - Detailed message.
      cause - Optional cause.
    • SqlBatchException

      public SqlBatchException(UUID traceId, int code, String message, @Nullable @Nullable Throwable cause)
      Creates an exception with the given trace ID, error code, detailed message, and cause.
      Parameters:
      traceId - Unique identifier of the exception.
      code - Full error code.
      message - Detailed message.
      cause - Optional nested exception (can be null).
  • Method Details

    • updateCounters

      public long[] updateCounters()
      Returns an array that describes the outcome of a batch execution.
      Returns:
      Array that describes the outcome of a batch execution.