IBM Support

FlatFile Adapter fails to process event file with unique constraint violation errors

Troubleshooting


Problem

If the FlatFile Adapter fails to process an event, and you move the same file again into the event directory, the Adapter will not process the file due to unique constraints violation errors.

Symptom

You encounter the following error message:


... com.ibm.j2ca.extension.utils.persistencestore.EventPersistenceDBImplbatchStore() CWYBS0650I: An SQL Exception occurred with the message The statement was aborted because it would have caused a duplicate key value in a unique or primary key constraint or unique index identified by 'SQL100922110632800' defined on 'EVENT'., while trying to batchStore().Explanation=The SQL query to do the above operation failed with the above mentioned message. UserAction=Check that the table and the corresponding columns exist in the database and that the connection exists in your J2EE server. Contact your database administrator to verify the connection properties. Try again with the changed connection properties.

Cause

If you put the same file in the event directory to be processed the second time, and there are already failed entries for the file stored in the database, the event id generated will be the same as the one that is already stored in the event database. This will cause the Adapter to throw the unique constraints violation error.

Resolving The Problem

Correct the failed file before putting it back into the event directory for reprocessing.

[{"Product":{"code":"SSMKUK","label":"WebSphere Adapters Family"},"Business Unit":{"code":"BU053","label":"Cloud & Data Platform"},"Component":"Adapter for FlatFiles","Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"7.0;6.2;6.1","Edition":"WebSphere","Line of Business":{"code":"","label":""}}]

Document Information

Modified date:
15 June 2018

UID

swg21449530