and date_ge(CAST(a.application_date as date),#{dto.beginDate})
and date_ge(CAST(a.application_date as date),#{dto.beginDate})
and date_le(CAST(a.application_date as date),#{dto.endDate})
and date_le(CAST(a.application_date as date),#{dto.endDate})
union all
union all
SELECT count(1) FROM "tzs_jg_use_registration" where receive_company_org_code like CONCAT(#{orgCode}, '%') and status != '使用单位待提交' and status != '使用单位已撤回' and status != '已作废' and status = '已完成' and date_ge(CAST(reg_date as date),#{dto.beginDate}) and date_le(CAST(reg_date as date),#{dto.endDate})
SELECT count(1) FROM "tzs_jg_use_registration" where receive_company_org_code like CONCAT(#{orgCode}, '%') and status != '使用单位待提交' and status != '使用单位已撤回' and status != '已作废' and status != '已完成' and date_ge(CAST(reg_date as date),#{dto.beginDate}) and date_le(CAST(reg_date as date),#{dto.endDate})
union all
union all
SELECT
SELECT
count(1)
count(1)
...
@@ -1031,7 +1031,7 @@
...
@@ -1031,7 +1031,7 @@
union all
union all
SELECT count(1) as num FROM "tzs_jg_change_registration_transfer" where receive_company_org_code like CONCAT(#{orgCode}, '%') and audit_status != '使用单位待提交' and audit_status != '使用单位已撤回' and audit_status != '已作废' and audit_status != '已完成' and date_ge(CAST(reg_date as date),#{dto.beginDate}) and date_le(CAST(reg_date as date),#{dto.endDate})
SELECT count(1) as num FROM "tzs_jg_change_registration_transfer" where receive_company_org_code like CONCAT(#{orgCode}, '%') and audit_status != '使用单位待提交' and audit_status != '使用单位已撤回' and audit_status != '已作废' and audit_status != '已完成' and date_ge(CAST(reg_date as date),#{dto.beginDate}) and date_le(CAST(reg_date as date),#{dto.endDate})
union all
union all
SELECT count(1) as num FROM "tzs_jg_change_registration_unit" where receive_company_org_code like CONCAT(#{orgCode}, '%') and status != '使用单位待提交' and status != '使用单位已撤回' and status != '已作废' and status = '已完成' and date_ge(CAST(apply_date as date),#{dto.beginDate}) and date_le(CAST(apply_date as date),#{dto.endDate})
SELECT count(1) as num FROM "tzs_jg_change_registration_unit" where receive_company_org_code like CONCAT(#{orgCode}, '%') and status != '使用单位待提交' and status != '使用单位已撤回' and status != '已作废' and status != '已完成' and date_ge(CAST(apply_date as date),#{dto.beginDate}) and date_le(CAST(apply_date as date),#{dto.endDate})
)
)
union all
union all
select count(1) from tzs_jg_scrap_cancel a, privilege_company b where a.receive_org_code= b.company_code and b.org_code like CONCAT(#{orgCode}, '%') and a.audit_status != '使用单位待提交' and a.audit_status != '使用单位已撤回' and a.audit_status != '已作废' and a.audit_status != '已完成' and date_ge(CAST(a.create_date as date),#{dto.beginDate}) and date_le(CAST(a.create_date as date),#{dto.endDate})
select count(1) from tzs_jg_scrap_cancel a, privilege_company b where a.receive_org_code= b.company_code and b.org_code like CONCAT(#{orgCode}, '%') and a.audit_status != '使用单位待提交' and a.audit_status != '使用单位已撤回' and a.audit_status != '已作废' and a.audit_status != '已完成' and date_ge(CAST(a.create_date as date),#{dto.beginDate}) and date_le(CAST(a.create_date as date),#{dto.endDate})