Application Development 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: 

dump when trying to update the itab " TABLE_ILLEGAL_STATEMENT"

Former Member
0 Kudos

Hi all,

When i try to update an internal table i get the dump TABLE_ILLEGAL_STATEMENT.

My code is as below:

read table l_fieldcat with key fieldname = 'CCARD1' into wa_fieldcat.

wa_fieldcat-seltext_M = 'Credit Card 1'.

wa_fieldcat-seltext_l = 'Credit Card 1'.

wa_fieldcat-seltext_s = 'Credit Card 1'.

Modify l_fieldcat from wa_fieldcat.

do you think i should add the clause sy-index to it ?

thanks,

Gols

4 REPLIES 4

Former Member
0 Kudos

HI,

Using SY-INDEX will be good in above Modify statement.

Please tell exactly at which line this error come??

Former Member
0 Kudos

As per my understanding

seltext_M will be of 10 character and you are assigning more characters to it , hence dump is coming .

Hope it resolves your issue .

former_member198275
Active Contributor
0 Kudos

Hi,

If 'modify' statement is not in the loop, then use 'modify table' and

read table l_fieldcat into wa_fieldcat with key fieldname = 'CCARD1'.

0 Kudos

Modify table is not in loop, i will try to use your solution now.

However my problem is solved using the sy-tabix addition,

thanks