Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Dump DATA_OFFSET_TOO_LARGE

Former Member
0 Likes
4,422

Hello Techies,

I am facing an issue with the dump called "DATA_OFFSET_TOO_LARGE".

Can anybody help me with the solution or sap note need to be applied.

please see the below code for your reference.

*&      Form  get_material_sap_form_02
 *&
 *       text
 *
 *        >P_RETURN  text
 *      <  P_L_RP_CHARGE  text
 *
 form get_material_sap_form_02  tables   p_return structure bapir
                                changing p_part.

   data: first_part(3)   type c,
         middle          type c,
         second_part(5)  type c.
   constants: s_abc(70)  type c value 'QWERTYUIOPASDFGHJKLZXCVBNM
   data: l_matnr like mara-matnr.


Regards,
Reshma

   if not p_part is initial.

     translate p_part to upper case.

     if p_part ca s_abc.
       if sy-fdpos >= 1.
         first_part  = p_part(sy-fdpos).
         middle      = p_part+sy-fdpos(1).
         sy-fdpos = sy-fdpos + 1.
         *second_part = p_part+sy-fdpos.                             This statement is giving an error.*         shift first_part right deleting trailing space.
         shift second_part right deleting trailing space.
         translate first_part  using ' 0'.

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
2,295

Hi,

Please check the length of your variable : p_part

say if the length is 3 , and the sy-fdpos is 4. you are trying to access the 4th character which is not available.

In your case I think the character you are checking is the last character and you get the dump.

say p_part is 3 char's

p_part = '12Q'.

if sy-fdpos >= 1. " sy-fdpos will be 2.

first_part = p_part(sy-fdpos). " first_part = 12

middle = p_part+sy-fdpos(1). " middle = Q

sy-fdpos = sy-fdpos + 1. " sy-fdpos will be 3.

*second_part = p_part+sy-fdpos. " here you are trying to access the 4th character , where as the length of the variable

p_part is only 3.

endif.

Regards,

Srini.

3 REPLIES 3
Read only

Former Member
0 Likes
2,296

Hi,

Please check the length of your variable : p_part

say if the length is 3 , and the sy-fdpos is 4. you are trying to access the 4th character which is not available.

In your case I think the character you are checking is the last character and you get the dump.

say p_part is 3 char's

p_part = '12Q'.

if sy-fdpos >= 1. " sy-fdpos will be 2.

first_part = p_part(sy-fdpos). " first_part = 12

middle = p_part+sy-fdpos(1). " middle = Q

sy-fdpos = sy-fdpos + 1. " sy-fdpos will be 3.

*second_part = p_part+sy-fdpos. " here you are trying to access the 4th character , where as the length of the variable

p_part is only 3.

endif.

Regards,

Srini.

Read only

nabheetscn
SAP Champion
SAP Champion
0 Likes
2,295

Hi,

This dump comes when you refer the contents of the fields(Offset) which are larger then the field size. debug it you will be able to solve it.

Nabheet

Read only

0 Likes
2,295

Hello Both,

This was helpful. And the issue is resolved now.

Thank you for your support.