注册

语句执行报错,嵌套分组函数没有 GROUP BY,其中GROUP_OPT_FLAG已经设置为了53

初心 2024/10/16 355 1 已解决

为提高效率,提问时请提供以下信息,问题描述清晰可优先响应。
【DM版本】:dm8
【操作系统】:centos7
【CPU】:x86
【问题描述】*:查询语句执行报错,显示嵌套分组函数没有 GROUP BY,其中GROUP_OPT_FLAG已经设置为了53
image.png

语句如下:
select nvl(sum(nvl(a.bill_amount, 0) -
(nvl(a.third_party_pay_amount, 0) + SUM(nvl(commer_insur_pay_amt,0)) +
nvl(a.other_amount8, 0) + nvl(a.deduct_amount, 0) +
nvl(a.self_charge_amount, 0) +
nvl(a.other_amount2, 0) +
nvl(a.unreasonable_amount, 0)) -
nvl(a.other_amount3, 0)),
0)
from gcm_medical_bill_info a
where a.is_valid = 'Y'
and a.other_amount7 <= a.medical_pay_top_level
and a.other_amount7 >= a.medical_pay_low_level
and a.claim_no = p_claim_no;

回答 0
暂无回答
扫一扫
联系客服