To provide an SQL script to assist in the identification of Projects (PA) revenue issues.
This script could prove very useful for PA revenue problems. It will sum up all the accrued and unearned revenue, thus providing a figure for the total revenue against a project.
select dr.draft_revenue_Num, sum(dri.amount) amt
from pa_draft_Revenues dr, pa_draft_revenue_items dr
where dri.project_id = dr.project_Id
and dri.draft_revenue_Num = dr.draft_revenue_Num
and dr.project_Id = &project_Id
group by dr.draft_revenue_Num;
Thanks – do share ur feedback – shivmohan