Showing posts with label #GeneralLedger. Show all posts
Showing posts with label #GeneralLedger. Show all posts

Friday, 28 April 2023

Oracle EBS - SQL Query to Get Pending Approval Journal Entry

 


SELECT 

    gjb.name BATCH_NAME, 

    decode(gjb.approval_status_code, 'A', 'Approved', 'I', 'In Process', 

               'J', 'Rejected', 'R', 'Required', 'V', 

               'Validation Failed', 'Z', 'N/A') APPROVAL_STATUS, 

    gjh.* 

FROM 

    gl_je_headers gjh, 

    gl_je_batches gjb 

WHERE 

        gjh.created_by = '3833' –USERNAME- HTRUONG , USER_ID=3833 

and gjh.creation_date >= sysdate-365 

    AND gjh.je_batch_id = gjb.je_batch_id 

    AND decode(gjb.approval_status_code, 'A', 'Approved', 'I', 'In Process', 

               'J', 'Rejected', 'R', 'Required', 'V', 

               'Validation Failed', 'Z', 'N/A') in ('Required','In Process') 

               ;