13.5 BatchSQLExceptionクラス

BatchSQLExceptionクラスは、バッチ処理エラーを処理するメソッドを提供します。BatchSQLExceptionクラスはSQLExceptionクラスから導出されるため、すべてのBatchSQLExceptionインスタンスは、表13-6に示したメソッド以外に、SQLExceptionのすべてのメソッドをサポートします。

表13-6 BatchSQLExceptionメソッドの概要

メソッド 概要

getException()

例外を戻します。

getFailedRowCount()

挿入または更新が失敗した行数を戻します。

getRowNum()

挿入または更新エラーのある行番号を戻します。

13.5.1 getException()

指定されたindexに一致する例外を戻します。

構文

SQLException getSQLException (
   unsigned int index) const;
パラメータ 説明
index

バッチ・プロセスによって戻されたエラー・リストに対する索引を指定します。

13.5.2 getFailedRowCount()

INSERT文またはUPDATE文が失敗した行の数を戻します。

構文

unsigned int getFailedRowCount( ) const;

13.5.3 getRowNum()

指定されたindexに一致したエラーのある行の番号を戻します。

構文

unsigned int getRowNum(
   unsigned int index) const;
パラメータ 説明
index

バッチ・プロセスによって戻されたエラー・リストに対する索引を指定します。