2013 Feb 27 5:54 PM
Hi Experts,
We sometimes get runtime error itab duplicate key in production system on the following select:
select data from BSIS into ITAB where burks on selection screen
gjahr on selection screen
select data from BSAS appending ITAB where burks on selection screen
gjahr on selection screen
ITAB is sorted table with unqiue key bukrs gjahr belnr buzei.
I belive the dump occurs because it finds duplicate record in BSAS for the same key (bukrs gjahr belnr buzei) and i can change my internal table to
non-unique key and it should resolve the error.
But when i check my dev system i dont see any records on BSAS for the key (bukrs gjahr belnr buzei) which are in BSIS.
Can someone please advice if this can happen in any scenario?
Thanks
Hi Experts,
We sometimes get runtime error itab duplicate key in production system on the following select:
select data from BSIS into ITAB where burks on selection screen
gjahr on selection screen
select data from BSAS appending ITAB where burks on selection screen
gjahr on selection screen
ITAB is sorted table with unqiue key bukrs gjahr belnr buzei.
I belive the dump occurs because it finds duplicate record in BSAS for the same key (bukrs gjahr belnr buzei) and i can change my internal table to
non-unique key and it should resolve the error.
But when i check my dev system i dont see any records on BSAS for the key (bukrs gjahr belnr buzei) which are in BSIS.
Can someone please advice if this can happen in any scenario?
Thanks
2013 Feb 28 3:48 AM
Hi Bhanu,
Just a thought - production system always contains real-time data hence maybe you need to analyze how the data is stored in BSIS and BSAS and replicate the same in DEV system and see what happens!
We generally do that. If we get a dump in Prod, we replicate it in Dev and correct the dump. Prod always has or is understood to have correct and real-time data unlike DEV which can have dummy data too.
Try this and let us know if this helps!
2013 Feb 28 9:26 AM
hi,
have you checked exactly whether there is a duplicate key???
here's a routine:
itab2 = itab.
loop at itab2 into wa2.
clear z.
loop at itab into wa where bukrs = itab-bukrs..."(all key-fields! in where clause)
...
add 1 to z.
endloop.
*check duplicate key when counter greater 1
if z > 1.
write: wa-bukrs, wa-belnr....
hope that helps
greetings
Andreas
| User | Count |
|---|---|
| 4 | |
| 2 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |