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

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
Morgoz
Contributor III
Contributor III

Compare date fields of same table in set expression

Hello,

I need to compare two dates that are stored in two different fields in the table, for a set expression:

 

 

Count({<EXEC_DATE_SQL = EXEC_DATE_SQL_MONTHLY>} TOTAL ID_DQ)

 

 

EXEC_DATE_SQL and EXEC_DATE_SQL_MONTHLY are Dates, the second changes depending on the first in the table.

If I chage the above code by this:

 

 

Count({<EXEC_DATE_SQL = {'2021-01-01'}>} TOTAL ID_DQ)

 

 

works fine.

Thank you.

Labels (1)
1 Reply
GaryGiles
Specialist
Specialist

In this case, you to need to use an if statement.

Count(Total if(EXEC_DATE_SQL = EXEC_DATE_SQL_MONTHLY,ID_DQ))