COGNOiSe.com - The IBM Cognos Community

IBM Cognos 10 Platform => Cognos 10 BI => Report Studio => Topic started by: priya@90 on 11 May 2016 09:24:05 AM

Title: Count Issue
Post by: priya@90 on 11 May 2016 09:24:05 AM
Hello,

I am facing an issue with count. i have an data item called emp_sk and iam doing count(emp_sk) and it should come total but report is giving individula records and report filters are [BU]='GPSD' etc

GPSD is having 11 records but in cognos its giving individual records as per attachment and also DB2 is giving correct result 11 records.

Please help to get total records as 11 not individual and i tried to apply grouping also but no luck

Thanks,
Priya



Title: Re: Count Issue
Post by: MFGF on 11 May 2016 10:55:03 AM
Quote from: priya@90 on 11 May 2016 09:24:05 AM
Hello,

I am facing an issue with count. i have an data item called emp_sk and iam doing count(emp_sk) and it should come total but report is giving individula records and report filters are [BU]='GPSD' etc

GPSD is having 11 records but in cognos its giving individual records as per attachment and also DB2 is giving correct result 11 records.

Please help to get total records as 11 not individual and i tried to apply grouping also but no luck

Thanks,
Priya

How about count([emp_sk] for [GPSD])

MF.
Title: Re: Count Issue-resolved
Post by: priya@90 on 11 May 2016 11:10:30 AM
Your Awesome MFGF gee and it's working perfectly . Thanks a lot i didn't try this with my less experienced.

Thanks,
Priya
Title: Re: Count Issue
Post by: priya@90 on 11 May 2016 11:17:20 AM
count([emp_sk] for [BU]) what does this mean exactly? what it will do? Can some one explain please.

Thanks,
Title: Re: Count Issue
Post by: MFGF on 12 May 2016 02:31:38 AM
Quote from: priya@90 on 11 May 2016 11:17:20 AM
count([emp_sk] for [BU]) what does this mean exactly? what it will do? Can some one explain please.

Thanks,

It will return a count of the number of emp_sk values for each BU value.

MF.