Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Sai_Mohan
Contributor III
Contributor III

Need to If Condtion when using Interval() in QlikSense

Hi All,

I have calculated Average  using Interval() in KPI and now i need to add extra condition for that KPI

1st Cond - Interval(avg((Start_Time- End _Time)),'hh:mm:ss')

2nd Cond - Date >= 07/01/2020.

I already have that 1st condition which gives average value (08:02:33) In KPI. Now i need to add 2nd condition in that KPI(Mentioned above as '2nd Cond').

Please help me with this

Thanks in advance!

 

Labels (3)
3 Replies
dplr-rn
Partner - Master III
Partner - Master III

i am assuming you have a separate date field in your table and the date condition you mentioned not dynamic

Interval(avg(  {<Date={'>=$(=MakeDate(2020,7,1))'}>} (Start_Time- End _Time)),'hh:mm:ss')

Sai_Mohan
Contributor III
Contributor III
Author

Thanks for the reply @dplr-rn !

 Date is column name 

'07/20/2020' - I need to hard code this in my set expression in the report.

I need to just include date condition(ie., date >= '07/20/2020') inside the Avg calculation.

 

 

dplr-rn
Partner - Master III
Partner - Master III

then above should work. make sure the date column is tagged as date (i.e.  $date $numeric...)