Joined: 31 May 2006 Posts: 200 Location: Netherlands
You can declare a counter variable, go on incrementing that after each updation and commit when it reaches 1000. But in case of abend you will still not be able to get the record for which the program abended so always implement the restart logic.
But this may create problems if the job abends in between. You need to restart the loading from the record which is next to the record which was last committed. This may not be possible in this case, since the input is from a flat file and you cannot direcly identify the records that were committed.
In my opinion, it is better not to have any commit logic in these scenarios.