cancel
Showing results for 
Search instead for 
Did you mean: 

ALV grid Display

Former Member
0 Kudos

Hi all,

Needed input about how to display all the wagetypes of pa0008 subty 11 in an ALV Grid format.No LDB is being used here.

The format has to be | Wagetype | Amount |.

Regards,

Amrita

Accepted Solutions (0)

Answers (3)

Answers (3)

Former Member
0 Kudos

Since you are not using LDB you can not use macros.

1. Use below Function module to get all the records on IT0008:

call function 'HR_READ_INFOTYPE'

exporting

tclas = 'A'

pernr = pernr-pernr

infty = '0008'

begda = pn-begda

endda = pn-endda

tables

infty_tab = p0008

exceptions

infty_not_found = 1

others = 2

.

if sy-subrc <> 0.

message e028 with 'Record not Found in Infotype 0008'.

endif.

2. Then you can loop for the subtypes you need and create ALV report using REUSE_ALV_GRID_DISPLAY Function module.

Former Member
0 Kudos

hi amrita,

0008 is a repetitive structures.so u have to write like following .fieldcat will be same like normal alv.

DATA: BEGIN OF wagetypes,

lga LIKE P0008-LGA01,

bet LIKE P0008-BET01,

END OF wagetypes.

RP_PROVIDE_FROM_LAST P0041 SPACE PN-BEGDA PN-ENDDA.

DO 12 TIMES VARYING wagetypes-lga FROM P0041-lga01

NEXT P0041-lga02.

IF wagetypes-lga IS INITIAL.

EXIT.

ELSE.

WRITE: / wagetypes-lga ,wagetypes-bet.

ENDIF.

ENDDO.

Former Member
0 Kudos

Hi Amrita,

Run Adhoc query : S_PH0_48000509

Select personnel number & Period as selection.

Then open Basic Pay folder.

Select Wage type amount & wage type.

Save & run.

This is hopefully the list you're looking for.

Regards,

Dilek

Former Member
0 Kudos

Hi,

Thanks for the response.

But i need to display it in an report. I need to write a report program for it.

Can u kindly help me with that?

Regards,

Amrita.