on 2022 May 13 9:38 AM
Hi Experts,
[1] SUM outside
select
COMP,
SUM( case when COMP = '1000' then count( "PERNR" ) else 0 end ) as "NUM"
from tab
;
[2] SUM inside
select
COMP,
case when COMP = '1000' then SUM( count( "PERNR" ) ) else 0 end as "NUM"
from tab
;
All got the same error : "SAP DBTech JDBC: [279]: group function is nested: ......."
So, how to sum the result of count value in one select statement ?
Request clarification before answering.
User | Count |
---|---|
31 | |
15 | |
10 | |
9 | |
7 | |
6 | |
6 | |
5 | |
5 | |
5 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.