Skip to Content
0
Former Member
Jul 09, 2007 at 12:15 PM

Passing value for multiple perners in smartform - VERY URGENT

25 Views

Hi All,

I have to pass a value "name1" in my smartform for multiple perners.

My table name is itab1. But i am not getting tha values.

please advice.

DATA: BEGIN OF ITAB_EMPNO OCCURS 0,

PERNR LIKE PA0001-PERNR,

END OF ITAB_EMPNO.

SELECT PERNR FROM PA0001 INTO TABLE ITAB_EMPNO WHERE PERNR IN P_PERNR.

SORT ITAB_EMPNO BY PERNR.

DELETE ADJACENT DUPLICATES FROM ITAB_EMPNO.

LOOP AT ITAB_EMPNO.

ITAB1-PERNR = ITAB_EMPNO-PERNR. " passing pernrs in itab1

AT END OF PERNR.

APPEND itab1.

CLEAR ITAB1.

ENDAT.

ENDLOOP.

LOOP AT ITAB1 .

read table it_0002 with key pernr = itab1-pernr.

if sy-subrc = 0.

ITAB1-NAME1 = IT_0002-NAME1.

APPEND ITAB1 .

endif.

ENDLOOP.

thanks & regards,

Preeti