Skip to Content
avatar image
Former Member

ALV grid Display

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

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

3 Answers

  • avatar image
    Former Member
    Oct 17, 2008 at 06:21 AM

    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

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member

      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.

  • avatar image
    Former Member
    Oct 17, 2008 at 07:00 AM

    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.

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Oct 18, 2008 at 07:45 PM

    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.

    Add comment
    10|10000 characters needed characters exceeded