02-04-2010 10:01 PM
Greetings,
We have expended KOMK through an append using SE11. We added code in the standard user exit and we can see that TKOMK gets our changes in its head line. However, once the user exit is done, the below code is executed in FV45PF0P_PREISFINDUNG_VORBEREI.
DATA: TKOMK LIKE STANDARD TABLE OF KOMK
WITH KEY KEY_UC
INITIAL SIZE 2
WITH HEADER LINE.
READ TABLE tkomk WITH KEY tkomk-key_uc.
IF sy-subrc NE 0.
APPEND tkomk.
tkomk-ix_komk = sy-tabix.
MODIFY tkomk INDEX sy-tabix.
ENDIF.
The issue is that since tkomk-key_uc is not a complete copy of tkomk, it does not see any of our changes (at the end of tkomk). Has anyone run into this? Is there a limit to the size of the key for an internal table? (This is all standard SAP code and I have checked OSS with no note referencing this at all). TKOMK-key_uc ends up as 3080 bytes, but that is about 50+ fields that are not accounted for between the key and TKOMK, so no changes in these 50+ fields will be saved. Thanks.
02-05-2010 1:31 AM
after appending the structure did u active and adjust the table using Se14. That should be the fix.
07-07-2010 12:54 PM
the key will only allow so many characters, we had to move our fields up higher in the structure so they would be seen in the key.
05-02-2016 6:35 PM
This is very old thread but the answer to this is for any custom enhancement to pricing header/item table, you should extend KOMKAZ or KOMPAZ structure and not KOMK, KOMP or KOMG.
For some requirement it might work directly extending KOMK, KOMP or KOMG but some problem could arise like what the thread starter originally had.
SAP standard program will refer to KOMKAZ,KOMPAZ if it wants to check customer enhanced field changes, not in KOMK/KOMP direct custom append structures.