I am getting the above error when writing some code(Not a single-group group function)
select '01 Arrears' as arrears,a.agreement_type as Agreement_type,a.agreement_status as agreement_status ,count(*) as count,a.prb_number as prb_number,a.prb_fund_type as fund_type,
sum(a.wkprem * ((to_date(sysdate,'dd/MM/yy') - trunc(a.paid_clear_to_date)) / 7) - sum(a.part_contribution_amt)) as sum_of_prem
from mi_ddso_wk_equiv_premium_v a
where trunc(a.paid_clear_to_date) < to_date(sysdate,'dd/MM/yy')
and a.agreement_status = 'A'
group by '01 Arrears',a.agreement_type,a.agreement_status,a.prb_number,a.prb_fund_type
However I had this working before fine in business object. I have now added sysdate in to my script to replace some prompts for Business Objects. Script below
select '01 Arrears' as arrears,a.agreement_type as Agrrement_type,a.agreement_status as agreement_status ,count(*) as count,a.prb_number as prb_number,a.prb_fund_type as fund_type,
sum(a.wkprem*((to_date(substr(@Prompt('1-Start Date','d',,mono,free),1,10),'dd/MM/yyyy')- trunc(a.paid_clear_to_date)) / 7))- sum(a.part_contribution_amt) as sum_of_prem
from mi_ddso_wk_equiv_premium_v a
where trunc(a.paid_clear_to_date) < to_date(substr(@Prompt('1-Start Date','d',,mono,free),1,10),'dd/MM/yyyy')
and a.agreement_status = 'A'
group by '01 Arrears',a.agreement_type,a.agreement_status,a.prb_number,a.prb_fund_type
select '01 Arrears' as arrears,a.agreement_type as Agreement_type,a.agreement_status as agreement_status ,count(*) as count,a.prb_number as prb_number,a.prb_fund_type as fund_type,
sum(a.wkprem * ((to_date(sysdate,'dd/MM/yy') - trunc(a.paid_clear_to_date)) / 7) - sum(a.part_contribution_amt)) as sum_of_prem
from mi_ddso_wk_equiv_premium_v a
where trunc(a.paid_clear_to_date) < to_date(sysdate,'dd/MM/yy')
and a.agreement_status = 'A'
group by '01 Arrears',a.agreement_type,a.agreement_status,a.prb_number,a.prb_fund_type
However I had this working before fine in business object. I have now added sysdate in to my script to replace some prompts for Business Objects. Script below
select '01 Arrears' as arrears,a.agreement_type as Agrrement_type,a.agreement_status as agreement_status ,count(*) as count,a.prb_number as prb_number,a.prb_fund_type as fund_type,
sum(a.wkprem*((to_date(substr(@Prompt('1-Start Date','d',,mono,free),1,10),'dd/MM/yyyy')- trunc(a.paid_clear_to_date)) / 7))- sum(a.part_contribution_amt) as sum_of_prem
from mi_ddso_wk_equiv_premium_v a
where trunc(a.paid_clear_to_date) < to_date(substr(@Prompt('1-Start Date','d',,mono,free),1,10),'dd/MM/yyyy')
and a.agreement_status = 'A'
group by '01 Arrears',a.agreement_type,a.agreement_status,a.prb_number,a.prb_fund_type