We have added search box. Key in SAP issue keyword to search
TopBottom

Announcement: wanna exchange links? contact me at sapchatroom@gmail.com.

RE: [sap-abap] Illegal access to a string (offset too large) as dump error in production system

Posted by Admin at
Share this post:
Ma.gnolia DiggIt! Del.icio.us Yahoo Furl Technorati Reddit

Posted by Ben Meijs Ctac (Product Manager SAP Developments)
on May 2 at 7:12 AM
Hi,

It seems that in IF v_string(1) = 'S' OR v_string(1) = 's'. => v_string is empty.
Prevent the dump by first checking if v_string is not initial.

This is a typical error when working with the STRING type: you cannot refer to length / offset of a string that is outside of the boundary of the actual length of the string.



Met vriendelijke groeten/ kind regards,

Ben Meijs
www.ctac.nl

---------------Original Message---------------
From: parameshwar_kandikata
Sent: Monday, May 02, 2011 7:00 AM
Subject: Illegal access to a string (offset too large) as dump error in production system

Hi all,

Please any one can advice me to overcome these problem while uploading the data to sap application system I am getting a dump error as illegal access to a string n the production server.

try.
concatenate p_appsin '/' p_name into p_apps1.
OPEN DATASET p_apps1 FOR INPUT IN TEXT MODE ENCODING DEFAULT.
IF NOT sy-subrc IS INITIAL.
v_no = '183'.
PERFORM message_text USING v_no.
wa_error-filnam = wa_epsfili-name.
wa_error-desc = v_text_ds.
APPEND wa_error TO i_error.
CLOSE DATASET p_apps1.
ELSE.
DO.
READ DATASET p_apps1 INTO v_string.
IF sy-subrc <> 0.
EXIT.
ENDIF.
IF v_string(1) = 'S' OR v_string(1) = 's'.
(error is coming at here after these line its fail to execute)
CONTINUE.
ENDIF.
SPLIT v_string AT c_tab INTO wa_datatab-sno
wa_datatab-aufnr
wa_datatab-vornr
wa_datatab-bednr "Mod-001++
wa_datatab-ebeln
wa_datatab-srvpos
wa_datatab-menge.

CASE sy-subrc.
WHEN 0.
IF wa_datatab-menge CA '1234567890'.
APPEND wa_datatab TO it_datatab.
ELSE.
v_no = '185'.
PERFORM message_text USING v_no.
wa_error = wa_datatab.
wa_error-filnam = wa_epsfili-name.
wa_error-desc = v_text_ds.
APPEND wa_error TO i_error.
ENDIF.
WHEN OTHERS.
v_no = '184'.
PERFORM message_text USING v_no.
wa_error-filnam = wa_epsfili-name.
wa_error-desc = v_text_ds.
APPEND wa_error TO i_error.
EXIT.
ENDCASE.
ENDDO.
CLOSE DATASET: p_apps1.
endif.
* TO catch some sysytem errors (exceptions).
catch cx_sy_file_access_error into oref.
text = oref->get_text( ).
endtry.

__.____._
Copyright © 2011 Toolbox.com and message author.

Toolbox.com 4343 N. Scottsdale Road Suite 280, Scottsdale, AZ 85251
Mark as helpful
View this online
  
Ben Meijs Ctac
SAP ABAP Helper

Posted helpful replies on 5 threads in a group to earn a Bronze Achievement
Popular White Papers

In the Spotlight
Which response to your Toolbox.com Groups post was the most helpful? Use 'Best Answer' to mark highest quality content.
_.____.__

0 comments:

Post a Comment

T r a n s l a t e to your language