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

Assistance with an expression

I need an expression that will do a count when a flag is not equal to true and a date is equal to a variable value.

I can get it to work in parts but not all together.  Really not sure what I am missing.

Count({1} If( islegacy-={'TRUE'} AND ENROLLFISCMTH = {'=$(vTodayFISCMTH)'} ,acct_id))

This is along the lines of what I have been trying with no luck.

1 Solution

Accepted Solutions
dplr-rn
Partner - Master III
Partner - Master III

is the variable evaluated already? i.e does the definition have an = at the start
if not use $(=vTodayFISCMTH)

View solution in original post

3 Replies
Channa
Specialist III
Specialist III

Count({<islegacy-={'TRUE'} ,ENROLLFISCMTH = {'=$(vTodayFISCMTH)'}>} acct_id)

Channa
MRitter
Employee
Employee
Author

Thank you.

 

Your expression is working for the legacy flag portion but it is not filtering based on the month.

 

I have 800 records that are not legacy and only 3 in the current month.  But this expression is returning the full 800.

I have verified the actual data and the value in the variable and they are both 2019002 for those 3 records.  None of the others should be counted as they are prior to this month.

dplr-rn
Partner - Master III
Partner - Master III

is the variable evaluated already? i.e does the definition have an = at the start
if not use $(=vTodayFISCMTH)