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

Giving dump while using lvc_s_styl

Former Member
0 Likes
650

Hi,

DATA : WA1 TYPE LVC_S_STYL,
           ITAB1 TYPE LVC_T_STYL.

WA1-FIELDNAME = '123'.
WA1-STYLE = '100000'.
APPEND WA1 TO ITAB1.

WA1-FIELDNAME = '123'.
WA1-STYLE = '100000'.
APPEND WA1 TO ITAB1.

LOOP AT ITAB1 INTO WA1.
   WRITE : / WA1-FIELDNAME,WA1-STYLE.
ENDLOOP.

While I am executing ,getting this error.

Runtime Errors         ITAB_DUPLICATE_KEY_IDX_OP

Date and Time          17.09.2012 15:26:12

Short text

     Error when inserting into a table with unique key.

I am not understanding why??.Need help from you.

Regards

Shek

Moderator message : Not enough re-search before posting, discussion un-marked as question.

Message was edited by: Vinod Kumar

Hi,

DATA : WA1 TYPE LVC_S_STYL,
           ITAB1 TYPE LVC_T_STYL.

WA1-FIELDNAME = '123'.
WA1-STYLE = '100000'.
APPEND WA1 TO ITAB1.

WA1-FIELDNAME = '123'.
WA1-STYLE = '100000'.
APPEND WA1 TO ITAB1.

LOOP AT ITAB1 INTO WA1.
   WRITE : / WA1-FIELDNAME,WA1-STYLE.
ENDLOOP.

While I am executing ,getting this error.

Runtime Errors         ITAB_DUPLICATE_KEY_IDX_OP

Date and Time          17.09.2012 15:26:12

Short text

     Error when inserting into a table with unique key.

I am not understanding why??.Need help from you.

Regards

Shek

Moderator message : Not enough re-search before posting, discussion un-marked as question.

Message was edited by: Vinod Kumar

2 REPLIES 2
Read only

gouravkumar64
Active Contributor
0 Likes
576

Hi,

Your

LVC_T_STYL is's primary key is  unique

for this if u declare 

WA1-FIELDNAME = '123'. like this

Dump will come.

plz assign different value

WA1-FIELDNAME = '123'.

WA1-FIELDNAME = '133'.

Thanks

Gourav.



Read only

0 Likes
576

Hi,

modify also not working ??

Regards

Shek