How to calculate the PO Status displayed on BWC page?
Hi,
How to calculate the PO Status (not Approval Status) displayed on BWC (Buyer Work Center) page using the authorization_status, cancel_flag, closed_code, closed_date columns from PO_HEADERS_ALL table?
I have derived it by compiling below case statement but was looking for Oracle's input.
(case
when closed_code = 'FINALLY CLOSED' then 'Finally Closed'
when authorization_status in ('APPROVED','REJECTED') and cancel_flag = 'Y' then 'Canceled'
when closed_code = 'CLOSED' and authorization_status = 'APPROVED' and nvl(cancel_flag,'N') = 'N' then 'Closed'
when authorization_status = 'REJECTED' and cancel_flag is null then 'Rejected'
when authorization_status = 'REJECTED' and cancel_flag = 'Y' then 'Canceled'