1 Reply Latest reply on Dec 9, 2017 3:41 AM by Sanjay Desai EBS

    SQL Query for Internal Requisition Incomplete Status

    1567114

      Hello,

       

      Need help to build a Query based on the Purchase Requsitiion status:

       

      It needs to basest on “Subinventory” of TEST-UU for “Preparer” which will be “Bob” and “Peter”.

       

      Please need help

        • 1. Re: SQL Query for Internal Requisition Incomplete Status
          Sanjay Desai EBS

          Run below SQL. If your requirement is  still  not satisfied then explain your exact  and clear requirements.

           

          SELECT PRH.TYPE_LOOKUP_CODE, PRH.ORG_ID,  PRH.AUTHORIZATION_STATUS, PRH.SEGMENT1 PR_NUMBER, PRH.PREPARER_ID, PAPF.FULL_NAME PREPARER_NAME, PRL.LINE_NUM, PRL.ITEM_ID, PRL.DESTINATION_SUBINVENTORY 

          FROM PO_REQUISITION_HEADERS_ALL PRH,  PO_REQUISITION_LINES_ALL PRL, PER_ALL_PEOPLE_F PAPF

          WHERE PRH.TYPE_LOOKUP_CODE = 'INTERNAL'

          AND PRH.AUTHORIZATION_STATUS = 'INCOMPLETE'

          AND PRL.REQUISITION_HEADER_ID = PRH.REQUISITION_HEADER_ID

          AND PRL.ORG_ID = PRH.ORG_ID

          AND PRL.DESTINATION_SUBINVENTORY = 'TEST-UU'

          AND PAPF.PERSON_ID = PRH.PREPARER_ID

          AND PAPF.FULL_NAME IN ('BOB', 'PETER')

          ORDER BY PRH.SEGMENT1, PRL.LINE_NUM DESC

          1 person found this helpful