Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Posting on Qlik Community is temporarily paused. Thank you for patience and we'll update you soon!
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

sum - count of two variables

hi all,

I am trying to create a sum for a unique id based on the count on two variables(Applied Year and Applied Ireland Year) meeting a certain condition (year 2018) - count of AppliedCalendar year = 2018 + count of Applied Ireland Calendar year = 2018. I tried the below formula - but it is not working.

Note: the year has to be 2018 for only one or the other.

any suggestions?

sum(aggr(Count({<[Applied.autoCalendar.Year]={"2018"}>} + {<[Applied (Ireland).autoCalendar.Year]={"2018"}>}) distinct [unique id]))

1 Reply
sasiparupudi1
Master III
Master III

sum(

aggr(

Count(

{<[Applied.autoCalendar.Year]={"2018"}> + <[Applied (Ireland).autoCalendar.Year]={"2018"}>} distinct [unique id]),

YourDimension)

)


or


Count(

{<[Applied.autoCalendar.Year]={"2018"},[Applied (Ireland).autoCalendar.Year]={"2018"}>} distinct [unique id])