09-23-2008 4:42 PM
Hi,
I am using 'BAPI_PRICES_CONDITIONS' to upload pricing data. When calling the BAPI repeatedly with different condition types it is giving dump with message 'DATA_OFFSET_TOO_LARGE'. This dump is due to the static variable defined and used to calculate the offset to read data from one of the character fields in include LCND_PRICES_INBOUNDF0G, line number 83. The length of the field VAKEY is 100 characters. When the BAPI is called for the 4th time and tries to get the value based on offset it gives a dump as the value in offset is exceeding 100 characters.
pc_vakey_oldsv_offset_kfrst(1) = ls_konh_old-vakeysv_offset_kfrst(1). - Its giving dump when the value in static variable sv_offset_kfrst exceeds 100.
Is there any way to clear the static variables declared in standard BAPI through our program before calling it recursively?
Best Regards,
Janani
09-23-2008 5:43 PM
Hi Janani,
You can normally get around problems like this by calling the BAPI in a separate session.
e.g.
call 'BAPI_PRICES_CONDITIONS'
destination 'NONE
tables
ti_bapicondct = gt_bapicondct
ti_bapicondhd = gt_bapicondhd
ti_bapicondit = gt_bapicondit
ti_bapicondqs = gt_bapicondqs
ti_bapicondvs = gt_bapicondvs
to_bapiret2 = gt_bapiret2
to_bapiknumhs = gt_bapiknumhs
to_mem_initial = gt_mem_initial
exceptions
update_error = 1
others = 2.
As this BAPI isn't RFC enabled you would have to wrap it in a bespoke version. The bespoke version having exactly the same interface but with the RFC attributes set, the code would simply call the normal BAPI.
Hope this helps.
Darren
09-23-2008 5:43 PM
Hi Janani,
You can normally get around problems like this by calling the BAPI in a separate session.
e.g.
call 'BAPI_PRICES_CONDITIONS'
destination 'NONE
tables
ti_bapicondct = gt_bapicondct
ti_bapicondhd = gt_bapicondhd
ti_bapicondit = gt_bapicondit
ti_bapicondqs = gt_bapicondqs
ti_bapicondvs = gt_bapicondvs
to_bapiret2 = gt_bapiret2
to_bapiknumhs = gt_bapiknumhs
to_mem_initial = gt_mem_initial
exceptions
update_error = 1
others = 2.
As this BAPI isn't RFC enabled you would have to wrap it in a bespoke version. The bespoke version having exactly the same interface but with the RFC attributes set, the code would simply call the normal BAPI.
Hope this helps.
Darren
09-23-2008 11:18 PM
04-04-2012 1:13 PM
Look at Note 1667278 - Condition upload: DATA_OFFSET_TOO_LARGE which should correct the problem
You wrote
its giving dump when the value in static variable sv_offset_kfrst exceeds 100.
Note correction ,
Delete Block |
|
Insert Block |
|
When problems arise in a standard program or FM look at OSS notes. (Look also at Note 1135984 - Conditions cannot be created with BAPI_PRICES_CONDITIONS for information)
Regards,
Raymond