Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
jbakerstull
Creator
Creator

Receiving incorrect count

When I apply this formula directly to a table and unselect "Include Null Values" in table under [Entry Exit Client Id], the table displays the correct count. When I placed the formula in a KPI, the count is much higher. I don't understand why. 

=Count({($<[Entry Date] = {"<=$(=EndDate)"}, [Entry Exit Has No Exit Date] = {'Yes'}>+$<[Entry Date] = {"<=$(=EndDate)"}, [Exit Date] = {">=$(=StartDate)"}>)*$<[Exit Destination] = {'Permanent housing (other than RRH) for formerly homeless persons (HUD)'}>}Distinct([Client Id]))

1 Reply
sunny_talwar

May be try this

Sum({($<[Entry Date] = {"<=$(=EndDate)"}, [Entry Exit Has No Exit Date] = {'Yes'}>+$<[Entry Date] = {"<=$(=EndDate)"}, [Exit Date] = {">=$(=StartDate)"}>)*$<[Exit Destination] = {'Permanent housing (other than RRH) for formerly homeless persons (HUD)'}>} Aggr(
Count({($<[Entry Date] = {"<=$(=EndDate)"}, [Entry Exit Has No Exit Date] = {'Yes'}>+$<[Entry Date] = {"<=$(=EndDate)"}, [Exit Date] = {">=$(=StartDate)"}>)*$<[Exit Destination] = {'Permanent housing (other than RRH) for formerly homeless persons (HUD)'}>}Distinct([Client Id]))
, DimensionFromYourChart))