Skip to Content
avatar image
Former Member

Approval Query For Purchase Request

Hello,

I need a query that whenever a purchase request is made for Item type 'F' i.e. Fixed assets item then an Approval should be generated. Am using SAP 9.2 PL 04

Thanks

Kalli

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

3 Answers

  • Best Answer
    Aug 16, 2017 at 09:25 AM

    Hi Kali,

    Try this

    SELECT distinct 'true' from OPRQ T0 inner join PRQ1 T1 ON T0.[DocEntry] = T1.[DocEntry] INNER JOIN OITM T2 ON T1.[ItemCode] = T2.[ItemCode]
    WHERE T2.[ItemType] ='F'
    
    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Aug 16, 2017 at 05:14 PM

    Thanks Balaji, but the Purchase Request adds directly without going into Approval Stages. I tried this query earlier with Purchase Order with OPOR table but it did not work for Approval in Purchase Order also.

    Regards

    Kalli

    Add comment
    10|10000 characters needed characters exceeded

  • Aug 20, 2017 at 02:02 PM

    Hi,

    Try this approval query:-

    SELECT Distinct 'True' FROM OPRQ T0 INNER JOIN PRQ1 T1 ON T0.[DocEntry] = T1.[DocEntry] WHERE $[$38.1.0] IN (select T2.itemcode from OITM T2 where T2.[ItemType] = 'F')

    Please note approval procedure will work only for header level not at row level. But approval procedure will work, if you document have only one row.

    Regards,

    Nagarajan

    Add comment
    10|10000 characters needed characters exceeded