Hi,
Try,
Sort your internal table by pernr.
use control break statements.
AT NEW PERNR.
call function 'BAPI_EMPLOYEE_ENQUEUE'
exporting
number = wa_0008-pernr
IMPORTING
RETURN = l_return1
ENDAT.
AT END OF PERNR.
call function 'BAPI_EMPLOYEE_DEQUEUE'
exporting
number = wa_0008-pernr
* IMPORTING
* RETURN =
ENDAT.
Hope it helpful,
Regards,
Venkat