Record selection in IT0000 (Actions) using LDB PNP

Hi Guys,
I am writing a report using LDB PNP, where I need to EXCLUDE the employees, if an action has been done on IT0000 for the reporting start date and end date.
Can anybody share the logic to do this using HR Macros or FM?
Thanks,
mini

Hi miniSAP!
I think this tip can help you.
You can make your job at follow form:
at "infotypes" declaration, use:
INFOTYPES: 0000 MODE N.
Inside "GET PERNR" event, you can get the informations using directly fm: HR_READ_INFOTYPE, because using "MODE N" at infotype declaration the standard system will not return any information about employee. In this form, you can make de filter of informations from fm HR_READ_INFOTYPE.
Best regards!

Similar Messages

  • Reading Locked records from HR table using LDB PNP

    Hi,
    I am trying to read the table pa0168 using LDB PNP.
    But the problem is that get pernr staement does not retrieve locked records i.e where PA0168-sprps eq "X'.
    Can anybody help me with this.
    I have to use LDB  so i don't want a solution of writing a select * for the pa0168 table.
    hence i have to use get pernr statement but it should also retrieve locked records.
    how can i achieve that.? please help
    Thanks
    GT
    Message was edited by: GT

    Hi GT,
    In the START-OF-SELECTION event, set the parameter value
    pnp-sw-ignorelockedrecords = 'N'.
    Good Luck,
    Suresh Datti
    ( Pl award points if the answer helps you )

  • Filter Data using LDB PNP

    Hi,
    I'm looking to filter data in a report which uses LDB PNP.
    When i enter the 'start dates' and 'end dates' the values goes into PN-BEGDA and PN-ENDDA respectively.
    I want to know whether the GET PERNR statement will filter out the data based on 'start dates' and 'end dates'
    or do i have to loop at each infotype and manually filter out.
    varun

    >
    Rajesh Paruchuru wrote:
    > [Here is the answer from SAP|http://help.sap.com/saphelp_47x200/helpdata/en/4f/d527ba575e11d189270000e8322f96/content.htm]
    >
    >
    GET PERNR fills the internal tables of infotypes that are declared for
    >  each employee  using the INFOTYPES statement. The internal infotype table
    >  is filled with all records existing  between the lowest and highest
    >  system date. The internal table has the name Pnnnn,  where nnnn is the
    > infotype number
    >
    > - Rajesh.
    That means its useless to give a selection criteria on the selection screen.
    GET PERNR will get all records, means it will just filter the employee numbers nothing else, everything you will have to do manually by using loops.
    Varun

  • Screen Change when using LDB - pnp

    Hi ,
    I am facing a strange problem.
    I am using LDB -> pnp and HRIN0013 as Master data rep ,
    in one of the programs that i developed.
    The Screen and program behave fine in the development server.
    Once i transport it to the production server, the Screen changes to something completely different.
    What i noticed is that in attributes -->'Report category assignment' , HRIN0013 is not present.
    This means that HRIN0013 has not been transported?
    What can the problem be and how can i fix it?? I need to get this in by tommorow. Help will be highly appreciated.

    Hi Sanchit,
    when I change the report class in an HR report, the system tells me for the change request number.
    This change request, introduces, I think, a new record in some customize tables, like t599C.
    There must be a record in this table, for the report class that you create.
    Hope this helps you,
    Carles

  • Coding ABAP using LDB PNP and authorizations problems

    This post requires a blend of ABAP and HCM skills.
    When coding my own ABAP using LDB PNP, the LDB will provide me with the employees selected but will skip those for which I do not have access (regarding Authorizations settings) to one or more of the infotypes declared in the program.
    As a programmer I would like to receive from the LDB the information that an employee is skipped so that I can handle the exception.
    Do you know how can I get this information from the LDB?
    Thanks

    I dont know if PNP can do it but PNPCE can:
    at END-OF-SELECTION call macro PNP_GET_AUTH_SKIPPED_PERNRS
    it will provide a list of skiped PERNRs
    for further info see docu PNPCE

  • Obsolete statements while using LDB PNP

    Hi,
    I am using LDB PNP, while extended program check it is showing  many obsolete statements like-
    tables : PERNR.
    infotypes
    RP_PROVIDE_FROM_LAST.
    What is the alternate to all these above statements.
    I searched the forum, but could not found anything. Please provide example.
    Thanks,

    That will bevary from system settings, In the standard reports, it will never give you the error/warning/informaton messages. But custom programs it will give as a absolete, But i can see many experts will use the these Macro's, We are doing world largest HR implemetation, Still we are using the same, Not a problem, you can avoid those messages.
    Only one way of avoiding is Using Provide statements.
    Regards,
    Mallikarjuna

  • How to use LDB PNP with ABAP objects in a program

    Hello,
    I am wondering if anybody has used the HR logical database(LDB) PNP with user defined ABAP objects in a program? I am using the FM- <b>LDB_PROCESS</b> but its not working. Also assigning PNP in the attributes section of the program -- so that I can use predefined fields from the LDB and then invoking the FM doesn't work -- throwing 'Logical database already active' error.
    I suppose even with the ABAP objects and the new FM -- I should still be able to utilize the pre-defined fields of the PNP database -- and also the built in authorizations. I cannot use GET PERNR and REJECT as they give errors. I understand that the use of HR-macros (RP-PROVIDE-FROM-LAST and et al.) are not allowed as they use the table work area -- which is not allowed in ABAP-OOPS.
    I would really appreciate if anyone could show me some insight regarding this. Thank you.
    Kshitij R. Devre

    Hi Kshitij
    It would be really good if we could use both together. But as I know, it is not possible. "GET pernr." is an event-like loop statement and so cannot be used in OO context. And I guess, the same restriction holds for the "LDB_PROCESS" since it uses LDB-specific processing.
    What I suggest you is to use standard and BAPI functions.
    Sorry for giving bad news...
    *--Serdar

  • Want to have own selection screen  in HR-ABAP report using LDB

    Hi experts,
            I am working on HR-ABAP report using LDB pnp and infotypes..But, here we get the built in selection criterion..but I want my own selection screen to be displayed..whats the solution for this??? Is it possible to create my own selection screen instead of default one..and how???
    Please help me..its very urgent..

    Hi,
    chk this out:
    Create Report Categories                                                                               
    In this step, you define the report categories and determine the layout
       of the standard selection screen for these report categories. You can 
       create report categories for programs or queries that are based on the
       PNP or PNPCE logical databases.                                                                               
    The definition of report categories is divided into two sections:                                                                               
    o   In the Change Report Category view, you define general attributes 
           such as sort order, input fields for date, and so on.                                                                               
    o   In the Change Selection Criteria view, you define which selection 
           fields of the logical database should be avaliable on the selection
           screen.                                                                               
    Example                                                                               
    You want to set up your system so that your employees can only start  
       evaluation reports for Payroll if they use a payroll area. Within a   
       payroll area, you should be able to select according to personnel     
       number. Additional selection criteria should not be possible and you  
       should not be allowed to enter a sort sequence.                       
    Standard settings                                                                               
    The standard system already contains report categories. You can find the 
    attributes of the report categories in the table.                                                                               
    Note the following five report categories in particular:                                                                               
    o   Report category ' ' is the SAP default report category for     
        programs that are based on the PNP logical database.                                                                               
    o   Report category PNPCE is the SAP default category for programs that  
        are based on the PNPCE logical database.                                                                               
    o   Report category '00000000' is the customer-specific default category 
        for programs that are based on the PNP logical database.                                                                               
    o   Report category '0PNPCE' is the customer-specific default category   
        for programs that are based on the PNPCE logical database.                                                                               
    o   Report category __X2001 is the default category for Queries  that    
        are based on an InfoSet of the PNP LDB.                                                                               
    o   Report category QUEPNPCE is the default category for queries that    
        are based on an InfoSet of the PNPCE LDB.                                                                               
    The default report categories are used when a report is called if    
        the report has not been assigned a report category.                  
    Parameters and Options for Report Categories of the LDB PNP and PNPCE  
    Parameters and Options in Screen Area General Data                     
       If you activate this parameter, you can only enter data on the data
       selection period if you use reports that have been assigned. The   
       same date entries are then used for the person selection as for the
       date selection.                                                                               
    o   Matchcode allowed                                                  
       If you activate this parameter, you have use of a Matchcode        
       pushbutton (search help) if you use reports that have been assigned.
       This pushbutton enables you to perform the person selection.                                                                               
    o   Sort allowed                                                       
       If you activate this parameter, you have use of a Sort pushbutton if
       you use report that have been assigned. This pushbutton enables you
       to define a sort order before you execute the report.                                                                               
    o   Organizational structure allowed                                   
       If you activate this parameter, you have use of an Org.Structure   
       pushbutton if you use reports that have been assigned. This        
       pushbutton enables you to perform the person selection.            
       Note:                                                              
       For more information about these options, see the online           
       documentation under this path:                                     
       SAP Library -> Human Resources -> Reporting in Human Resources     
       Management -> Standard HR Reports -> Report Selection Screen in    
       Human Resources Management.                                                                               
    Parameters and Options in Screen Areas Data Selection Period/Person    
    Selection Period/Payroll Area/Period/Year                                                                               
    o   Options for data selection period and person selection period (key 
        date and so on)                                                    
        Here you define which options for date and person selection are    
        available for reports that have been assigned.                                                                               
    o   Options for payroll area/period/year                               
        Here you define which options for selection using payroll          
        area/period/year are available for reports that have been assigned.                                                                               
    Parameters and Options in Screen Area Selection View                                                                               
    o   Type/Name                                                          
        This parameter enables you to use selection views to define report 
        categories. You use the selection view selected here to determine  
        which fields are available in the Dynamic Selectionsy.                                                                               
    Note:                                                              
        You create selection views for the PNP and PNPCE logical databases 
        in the Object Navigator (SE80):                                    
        1. Start the Object Navigator (SE80)                               
        2. Choose Workbench -> Edit Object.                                
        3. Choose the More... tab page and the Selection view on this tab  
        page.                                                              
        4. Choose Create.                                                  
        5. In the Create Selection View dialog box, choose the For any     
        tables option.                                                     
        6. In the Name of view field, enter a name for your selection view.
        7. In the Tables dialog box, enter the name of the table from which
        you want to use fields.                                            
        Note:                                                              
        When you enter the table name, observe the naming convention in    
        Personnel Administration:                                          
        Infotype number: nnnn -> table name: PAnnnn                        
        8. Choose Continue.                                                
        9. In the Functional groups area, define functional groups by      
        assigning a name and a number.                                     
        10. Assign fields from the selected tables to the functional groups
        by entering the number of the desired functional group in front of 
        each field.                                                        
        11. Save your entries.                                                                               
    For more information about adjusting the dynamic selections using 
    your own selection views, see the online documentation under the  
    following menu path:                                              
    SAP Library -> Human Resources -> Reporting in Human Resources    
    Management -> HR Standard Reports -> Report Selection Screen in   
    Human Resources Management -> Enhancing the Selection Screen -    
    Dynamic Selections.                                                                               
    If you do not want to offer dynamic selections, make the following
    settings:                                                                               
    -   LDB PNP: In the Selection view field, enter PNP_NO_FREE_SEL.  
    -   LDB PNPCE: Leave the Selection view field empty.                                                                               
    Parameters and Options in Screen Area Data Selection Period/Person   
    Selection Period/Payroll Area/Period/Year                                                                               
    o   Available input parameters, date or period entry (today, key date,
       all, and so on), and standard value.                             
       Using the Standard value option, you define which of the selected
       options is shown.                                                                               
    Parameters and Options in Screen Area CE Selection Fields                                                                               
    o   CE selection fields (external person ID, grouping reason, grouping
       value)                                                           
       Using the options in this area, you define whether the external  
       person Id, grouping reason, or grouping value are available on the
       selection screen.                                                
       Note:                                                            
       These parameters are only relevant for you if you implement      
       Concurrent Employment (see also note 517071).                                                                               
    Parameters and Options in Screen Area Selection view                                                                               
    o   Dynamic selections as dialog box                                  
        If this switch is set, you can call the dynamic selections as a   
        dialog box.                                                                               
    o   Dynamic selections active                                         
        If this switch is set, the dynamic selections of the logical      
        database are active at the start of the report.                                                                               
    Note that the following combinations are possible for the last two
        options mentioned:                                                                               
    Dyn.Sel. as dialog box/Dyn.Sel. active: inactive/inactive         
        Dyn.Sel. as dialog box/Dyn.Sel. active: inactive/active           
        Dyn.Sel. as dialog box/Dyn.Sel. active: active/inactive                                                                               
    Activities                                                                               
    1.  Choose Edit -> New entries.                                                                               
    2.  Enter an abbreviation and a long text for the report category.         
        The customer name range for report categories is 0-9.                                                                               
    3.  Select the For the PNPCE logical database checkbox, if you want to     
        create a report category for a program or for queries of the PNPCE     
        logical database.                                                                               
    4.  In the General Data screen area, choose the desired options.           
        If you want to use selection IDs, you must have first created and      
        grouped selection Ids. The IMG path to do this is given in the         
        parameter description section.                                                                               
    5.  In the Data selection period/person selection period or Selection      
        period screen area, choose the desired options.                                                                               
    6.  In the Selection view screen area, choose the desired options.                                                                               
    7.  In the CE selection fields screen area, choose the desired (only       
        possible for report categories of the LDB PNPCE).                                                                               
    8.  Save your entries.                                                                               
    9.  Choose the subactivity Permitted selection criteria.                                                                               
    10. Choose Edit -> New entries.                                                                               
    11. In the Select option field, use the input help to select each field    
        that should be available on the selection screen.                                                                               
    12. Select the checkbox in the 1.page column, if you want this selection   
        field to be available directly when you call the selection screen.                                                                               
    Further notes                                                                               
    13. If you want to copy entries, you still have to enter the selection     
        parameters again in the subsequent screen.                                                                               
    o   If you create the report category '000000000', a selection screen is   
        generated according to report category '00000000'for all reports for   
        which a report category has not explicitly been assigned.                                                                               
    Assign Report Categories                                                                               
    In this step, you assign a report category to your reports.                                                                               
    Example                                                                               
    You have created your own report, for example ZPCTEST1, and would like
        it to have the selection screen that corresponds to that of the       
        evaluation report for Payroll, which is assigned to report category   
        '__M00001'.                                                           
        Assign report category '__M00001' to the report.                                                                               
    Requirements                                                                               
    You must have defined the Report Categories.                                                                               
    Standard settings                                                                               
    SAP Standard Reports:                                                                               
    In the standard system, reports are assigned a report category. If you
        want to override these assignments, perform the activities described  
        here. If you want to assign report categories to standard reports using
        SE38, this represents a modification.                                                                               
    Customer-Specific Reports:                                                                               
    For reports you have developed yourself, you can either assign report 
        categories by performing the activities described here or directly in SE38.
    Recommendation                                                                               
    Only assign a report category if you have created your own reports or if  
    the selection screens in the standard system do not meet your             
    requirements.                                                                               
    Activities                                                                               
    1.  Choose Edit -> New entries.                                                                               
    2.  Perform the required assignment using the Program name and Report     
       category fields.                                                                               
    3.  Save your entries.                   
    reward if helpful
    regards,
    madhumitha

  • Make (LDB)PNP Fields obligatory on selection-screen

    I am using LDB PNP.. I want to make some fields of PNP as obligatory. How Can I do that?
    So far I am doing the following...
    <b>Initialization.
    PNPABKRS-LOW = '?'.
    Append PNPABKRS.
    At selection-screen.
    if PNPABKRS-LOW is initial.
    PNPABKRS-LOW = '?'.
    Message e100(z01).
    endif.</b>
    What you suggest ?
    Thanks
    Message was edited by: Saquib Khan

    You have to do this way,
    AT SELECTION-SCREEN OUTPUT.
      LOOP AT SCREEN.
        IF SCREEN-NAME = 'PNPABKRS-LOW '.
          SCREEN-REQUIRED = 1.
          MODIFY SCREEN.
        ENDIF.
    ENDLOOP.

  • LDB PNP authorization check at record level - rp_provide_from_last

    hi,
    i am using LDB PNP,
    I am using macro 'rp-provide-from-last' .
    I neeed to place a authorization check so that the user of the program should only be allowed to view records of the people which comes under the same personnel area as of the user of the program.
    Can you please guide me on how to implement this?
    thanks in advance,
    akash.

    Hi,
    (1)
    Actually, if you're wirting report with PNP LDB, you do NOT need to do this hard-coded auth checking at all. Because the LDB abap code behind PNP has already do this job for you.
    So all you need to do is to ask you HR consultant or Basis consultant to modify the authority config of certain ROLE with t-code PFCG, and then assign that ROLE to certain user with t-code SU01.
    ABAP code behind PNP will automatically verify the current user according to his ROLE setting.
    (2)
    In some case you do not work with LDB report, then you need to do the authority check by yourself. General function  AUTHORITY_CHECK is what you need.  AUTHORITY_CHECK do the authority check by means of Authority Object.Belows are authority objects used in HR module(you can also see in PFCG if technial name switched on):
    P_ORGIN    HR: Master Data
    PLOG       Personnel Planning
    P_PCLX     HR: Clusters
    P_TCODE    HR: Transaction codes
    Sample of checking personal area:
    CALL FUNCTION 'AUTHORITY_CHECK'
         EXPORTING
              FIELD1              = ' PERSA'
              OBJECT              = 'P_ORGIN'
              USER                = 'SAPSUPPORT1'
              VALUE1              = 'Z001'  
         EXCEPTIONS
              USER_DONT_EXIST     = 1
              USER_IS_AUTHORIZED  = 2
              USER_NOT_AUTHORIZED = 3
              USER_IS_LOCKED      = 4
              OTHERS              = 5.  
    IF SY-SUBRC NE 2.
    MESSAGE E001(01) RAISING AUTH_FAILED.
    ENDIF.
    Reward if helpful pls!

  • Cannot use Is Null in record selection

    I cannot use Is Null in a record selection expert.  I use the same wording in excel and SQL QA with no issues.
    I need all records that are not '5 - Project' including Nulls.  Once I put the criteria of '5 - Project' it excludes the null records.
    {@dtCompleted} = {?Completed_Date_ Range} and
    {TASKS.TYPE} = "Information Technology" and
    {TASKS.PRIORITY} <>'5 - Project'
    This does not give me the nulls for the Priority field.
    The one I use in QA or in Excel is
    {@dtCompleted} = {?Completed_Date_ Range} and
    {TASKS.TYPE} = "Information Technology" and
    ({TASKS.PRIORITY} <>'5 - Project' or {TASKS.PRIORITY} is null)
    This gives me the "The ) is missing" error.  Help!

    (isnull({TASKS.PRIORITY}) or {TASKS.PRIORITY} <>'5 - Project')
    and
    @dtCompleted} = {?Completed_Date_ Range} and
    {TASKS.TYPE} = "Information Technology";
    Make sure that under File | Report Options or under File | Options the the box next to "Convert Database Null values to default' is NOT checked.
    {TASKS.PRIORITY} NOT EQUAL TO '5 - Project'.  Use the Greater than and less than symbols.
    Edited by: Sanjay Kodidine on Feb 27, 2009 8:49 PM

  • How to get a default variant screen using LDB.(HR-ABAP)

    Hello,
                   I have created a report using LDB PNP.Used HRBEN000 as a hr report category.
    Got a default selection screen, I want to add one more field, for this I have selected the field from further
    selection button, and displayed on the screen. Now i saved as a variant.
    how to get this default screen using the variant in the report/program when executed?
    Please help me.
    Thanks&Regards,
    Archana.

    Hi ,you camn always make your Z report category...if the field is present in further selection tab..
    if not you can create your own paramerter or select option.....
    but you have to handle it in your code ....as get pernr wont filter on its basis(parameter select optyin created by you)
    but why loop at screen is not working?
    let me know how you are doing...
    have to do it in at selection-screen output

  • Adding pushbutton in application toolbar of HR programs  using LDB

    Hi all!
    I have a requirement to add a pushbutton in the selection screen application tool bar for the HR programs when using LDB PNP.
    Normally when we are using LDB in our program we will get a extra button provided by SAP after the execyte button. When we are creating a new button for this by using the table fields sscrfields with the function key as 2.
    But, the statement "SELECTION SCREEN FUNCTION KEY 1" is not showing any pushbutton in the application toolbar.
    The same question is already posted in SDN but no reply.
    Please provide your suggestion.
    Thanks,
    Rajan U

    Hi all!
    I have a requirement to add a pushbutton in the selection screen application tool bar for the HR programs when using LDB PNP.
    Normally when we are using LDB in our program we will get a extra button provided by SAP after the execyte button. When we are creating a new button for this by using the table fields sscrfields with the function key as 2.
    But, the statement "SELECTION SCREEN FUNCTION KEY 1" is not showing any pushbutton in the application toolbar.
    The same question is already posted in SDN but no reply.
    Please provide your suggestion.
    Ive found this keyword: SELECTION-SCREEN FUNCTION KEY n [ldb_additions].  Will this be useful??
    Thanks,
    Rajan U

  • Get pernr in screen 900 for ldb PNP

    hi All,
    I have created a program in HR-ABAP using ldb pnp and I have used the screen 900 [for get payroll]  Now for few employees when I use GET pernr, its nt giving ne results. as in the the program goes to end of selection. Now wen i change the screen to normal [ blank or 000], the get pernr for same employees gives me results. Can someone please explain the reason for above?
    thanks,
    RS

    Check whether the payroll run has taken place for the input employee numbers you are giving.
    You can check in the Tcode PC_PAYRESULT.

  • Get pernr in creen 900 for ldb PNP

    hi All,
    I have created a program in HR-ABAP using ldb pnp and I have used the screen 900 [for get payroll]  Now for few employees when I use GET pernr, its nt giving ne results. as in the the program goes to end of selection. Now wen i change the screen to normal [ blank or 000], the get pernr for same employees gives me results. Can someone please explain the reason for above?
    thanks,
    RS

    Hi Reena
    Check the status of employees for no result is displayed in 900 screen. Either they are active or payroll is run or not. That might be one of the reason. Another reason can be they are being open for the changes.
    Regards
    Waz

Maybe you are looking for

  • How Do I Move Production from one Transport Domain to another

    Hi, We are prepping for our upgrade from R/3 4.7 to ERP 6.  I have created new Dev and QAS systems in a new transport domain for the upgrade.  A new transport Domain was created for the upgrade landscape, and a placeholder "virtual" system was create

  • How to delete a blog entry in Lion Server Wiki?

    Anyone know how to do this?  It seems that even logged in as system administrator you cannot delete blog entries using the web interface.  Wiki help unhelpfully reports that "If Delete Page or Delete File isn't listed, you can't delete the page or fi

  • I can't use airplay from iphone/ipad when I update the system

    It has been showed that "an error occurred loading this content, try again later". how can i fix that? and why apple TV can't output the sound to the AirPort Express on wifi? only airpay???? so stupid...

  • Duplicate post deleted by Moderator.

    xxxxxxxxx

  • OUTER JOIN behaviour

    Hi, I have a Fact table which is joined with two Dim tables: FACT -----DIM1 (FACT.key_col1= DIM1.key_col(+) ) \__DIM2 (FACT.key_col2= DIM2.key_col(+) ) Logical column: col1 = DECODE(DIM2.val, 0, DIM2.desc, DIM1.desc) In the business model: FACT >----