Neoview Database Administrator's Guide (R2.2)

If this happens, when the task is recovered the rejected record is processed again and is written
for a second time to the input.bad file for that task.
If records are being rejected on the Neoview platform, these records are sent to the gelserver
data-load process to be written to the sql.bad file for that task. After writing the rejected records
to the sql.bad file, the gelserver data-load process sends an acknowledgement to the Neoview
gelserver process.
If the gelserver data-load process terminates for any reason, including a STOP command, before
it sends the acknowledgement to the Neoview gelserver process that sent the rejected records,
the recovery point for the Neoview gelserver process will be such that it resends the rejected
records when the task is recovered. Depending on how many of rejected records were originally
written before the Linux gelserver terminated, this can lead to duplicate records in the sql.bad
file for that task.
To check for duplicate records in the sql.bad file, examine the task instance log and check the
last warning message for a record rejected by SQL. That message shows the record number in
the sql.bad file for that rejected record. Compare this record number with the cumulative total
(Ctot) in the STATS for the rejected records. If these numbers do not match, there are duplicate
records in the .sql.bad file.
In this example, 45,169 rejected records were written to the sql.bad file, but there were actually
only 45,000 actual rejected records in the input data. If you corrected and then resubmitted all
of the records from the sql.bad file for an INSERT task, you would receive duplicate record
errors. Example 8-3 shows a .bad file with duplicate records.
Example 8-3 Duplicate records in a .bad file
[12:19:06] WRITER_8> WARNING : WRT_8 Record rejected by SQL.
(SQLCODE -8102, Bad Rec #45169).
[12:19:06] WRITER_8> INFO : WRITER [ Dist. Wait: 15642ms & Write Prepare
Wait: 3ms & Write Execute Wait: 7415ms.
[12:19:06] WRITER_19> INFO : WRITER [ Dist. Wait: 13635ms & Write Prepare
Wait: 1ms & Write Execute Wait: 9459ms
[12:19:06] WRITER_25> INFO : WRITER [ Dist. Wait: 13284ms & Write Prepare
Wait: 0ms & Write Execute Wait: 9842ms
[12:19:06] WRITER_11> INFO : WRITER [ Dist. Wait: 14368ms & Write Prepare
Wait: 0ms & Write Execute Wait: 8793ms
[12:19:06] WRITER_1> INFO : WRITER [ Dist. Wait: 14052ms & Write Prepare
Wait: 0ms & Write Execute Wait: 9115ms.
[12:19:07] MASTER> MASTER Threads completed with success.
[12:19:07] MASTER> STATS
----------------------------------------------------------------
PNo. Requested Applied Rejected Affected
0 133032 133032 1277 131755
1 133932 133932 1181 132751
2 132592 132592 1250 131342
3 132853 132853 1134 131719
4 133303 133303 1200 132103
5 133425 133425 1211 132214
6 133407 133407 1259 132148
7 133128 133128 1194 131934
8 132617 132617 1182 131435
9 133362 133362 1264 132098
10 134094 134094 1150 132944
120 Using the Neoview Loader