leading-project/dw/dws/dws_business_bill_m.sql

14 lines
410 B
MySQL
Raw Normal View History

2024-07-21 22:06:45 +08:00
select
a.project_id
, a.project_name
, a.accrual_month
, sum(a.current_sure_money) current_sure_money
, sum(a.received_money) received_money
, sum(a.areare_money) areare_money
from dwd_business_contract_bill_d a
inner join dwd_business_contract_info_d b
on a.contract_id = b.id
group by
a.project_id
, a.project_name
, a.accrual_month