1. Get rid of all advertisements and get unlimited access to documents by upgrading to Premium Membership. Upgrade to Premium Now and also get a Premium Badge!

Link between Purchase Requisition and RFQ

Discussion in 'Oracle SCM & Manufacturing' started by saalmank, Feb 26, 2010.

  1. saalmank

    saalmank Active Member

    Messages:
    5
    Likes Received:
    0
    Trophy Points:
    55
    Location:
    Multan
    How can we get the RFQ of a Requistion using SQL ?
    eg. RFQ# = 47, and i want to search the requisition number of that RFQ.
     
  2. apps_expert

    apps_expert Forum Expert

    Messages:
    325
    Likes Received:
    28
    Trophy Points:
    330
    Location:
    Chennai, India
    The following sql script can be used to identify all req-rfq links (the order by clause can be changed according to your need)

    Code (SQL):

      SELECT   rh.segment1 REQ_NUM,
               rl.requisition_line_id,
               rl.requisition_header_id,
               ph.segment1 RFQ_NUM,
               pl.po_header_id,
               pl.po_line_id
        FROM   po_requisition_headers_all rh,
               po_requisition_lines_all rl,
               po_headers_all ph,
               po_lines_all pl
       WHERE       rh.requisition_header_id = rl.requisition_header_id
               AND rl.last_update_date = pl.creation_date
               AND pl.po_header_id = ph.po_header_id
               AND rl.on_rfq_flag = 'Y'
    ORDER BY   requisition_line_id DESC;
     
     
    saalmank likes this.