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

Sy-subrc fail scenerio's while modify statement

Former Member
0 Likes
2,509

Will there be a condition for modify statements when the sy-subrc will not be equal to zero?

Will there be a condition for modify statements when the sy-subrc will not be equal to zero?

4 REPLIES 4
Read only

mayur_priyan
Active Participant
0 Likes
1,690

Are you asking the reason/cause when sy-subrc is not equal to 0 after modify ?

When sy-subrc <> 0, it means that at least one line could not be processed as there is already a line with the same unique name secondary index in the database table.

Read only

0 Likes
1,690

Hi mayur,

              i am having a doubt whether there will be any situtaion where sy-subrc will fail for modify statement.

regards,

Midhun l madhu

Read only

vikas_mulay2
Participant
0 Likes
1,690

Hi Midhun,

Yes...you will have a condition when sy-subrc will not be '0'.

  • MODIFY sets SY-SUBRC to 0 if the operation is successful, otherwise to 4.

Regards,

Vikas

Read only

Former Member
0 Likes
1,690

Hi,

ABAP keyword help in SE38/SE80 for

MODIFY itab.

MODIFY dbtab.

will give you the answer, when SY-SUBRC is set to 4.

Regards,

Klaus