SAP HR ABAP, HCM Training Material and Tutorials

14
Feb

SAP ABAP HR Program code using LDB PNP

Bookmark and Share

Here is a basic abap hr program with screen shots step by step for learners who are having knowledge of abap. This is a basic program but you can use this template for every abap hr program and add if and else conditions change the Infotype numbers and field names based on your requirement.

Initially I don’t want to confuse the readers adding more coding at first program. All the scenarios are covered in next posts one by one by using the same program template.

Requirement: Select the data from Infotypes using logical database PNP (with out single select statement) and display in report. Fields like

Personnel number, Action Type, Reason for Action, Payroll area, Personnel ID Number

Infotypes Used: 0000, 0001, 0002.

Macros used:

RP-PROVIDE-FROM-LAST P0000 SPACE PN-BEGDA PN-ENDDA.

RP-PROVIDE-FROM-LAST P0001 SPACE PN-BEGDA PN-ENDDA.

RP-PROVIDE-FROM-LAST P0002 SPACE PN-BEGDA PN-ENDDA.

Selection screen:

There is selection screen is defined in this program but by using logical database PNP we do get standard selection screen.

selection screen

Steps:

1) Go to se38 transaction

2) Enter the program name ZABAPHROVERVIEW and press on create

3) Enter the TITLE name, select TYPE as executable program, and LOGICAL DATA BASE AS PNP.

first program

4) Press on save button.

And use the below code and execute you will get standard selection screen.

zabaphroverview

Standard selection screen:

selection screen

Enter the personnel number and execute the program report display is ready for you…:)

Don’t you feel abap hr is easy…. :)

Incase any question use the below comments section…..

Related Posts

17 Responses to “SAP ABAP HR Program code using LDB PNP”

  1. 1
    duns number lookup Says:

    Great posting ! Thank for sharing.

  2. 2
    chinna reddy gaddam Says:

    give me some sample payroll report and design the pay slip.

  3. 3
    admin Says:

    Hi Reddy,
    In near future You will see more payroll programs using Function modules, Macros and get event…. Keep watching…..

    http://abaphr.com

  4. 4
    Ravindranath Says:

    Hi Please let me know about the corse details and course.Please send it to ID mentioned in.it

  5. 5
    Ramakrishna Says:

    Hi,

    I would like to learn ABAP HR online training. Please send me the details

    Ramakrishna Moturi

  6. 6
    Urgent Leads Says:

    This blog site is wonderful. How did you come up witht he idea?…

  7. 7
    Khaja Moulali Says:

    so nice to Brgin HR ABAP.

    Thanks.

    Regards,
    Khaja Moulali.

  8. 8
    rahul Says:

    very good

  9. 9
    carol Says:

    Hi,

    I would like to learn ABAP HR, please send me the online training details or materials to the mail id provided.

    Thanks,
    Carol.

  10. 10
    Sujatha Says:

    i would like to take training on ABAP HR. could u pls inform the course Duration ,fee,location details indetailed.

  11. 11
    ALways Learner Says:

    Nice program to begin with :)

  12. 12
    Kushal Says:

    Smart n simple..gud 1

  13. 13
    Deviprasad Says:

    It is a very good site for basic abapers who want to learn the HR ABAP. Thanks for the post and am looking forward for more post.

  14. 14
    sriram Says:

    While selecting the employees based on Emp . personnel area, sub area, Company code, Emp.Group, Emp.Subgroup, PNP LDB not fetching any values.

    If we give Pernr or payroll area LDB PNP is fetching values .How do we change this? Why is this Happening?

  15. 15
    Irma Suriani Says:

    Waw, that’s very good actually.
    Hm anyway, i have any problem with the standard selection screen.
    My user ask me just want to use Payroll Area Field on the screen when she run the report and the others are not required to show. So, i have tried to edit it from Further Selection, but when she run the report again, she complains due to parameters not required. Is it possible to make just Payroll Area Parameter displayed when the program run ?

  16. 16
    admin Says:

    Yes, It is possible. There are several ways to modify the standard selection screen. If you need more information you can reach me on skype. go to contact page and get my skype name.

  17. 17
    M Says:

    HI RamakRishna,

    Woww, Good Site. …

    Though, we are Developers. Y can’t we debug the Macro’s. If it is posible. Y we are still using macros, even those are obsolute in current version and SAP it self suggesting don’t use Macro’s. Y can’t we use latest Statements or Y can’t we use Select Statements ..

    Thanks & regards,
    P . KM

Leave a Reply

© 2012 SAP HR ABAP, HCM Training Material and Tutorials | Entries (RSS) and Comments (RSS)

Design by Web4 Wordpress Themes, © SAP HR ABAP, HCM Training Material and Tutorials 2012 | Theme design by Data sub systems.
SAP is a registered Trademark of SAP AG. Abaphr.com is not affiliated to SAP AG or any of its subsidiaries.