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

Announcements
Join us in Bucharest on Sept 18th for Qlik's AI Reality Tour! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
sunil1989
Contributor
Contributor

Calculate variance

Hi ,

I am new to the qlik.

My requirement is i have to calculate the variance on the DeliveryStartDateTime and store dimension i.e.

count(orderid)/count(orderid) where DeliveryStartDateTime= DeliveryStartDateTime - 7

but i am not able to handle this in set analysis can any one help on this.

Should i handle this at script level or at expression level?

i have tried below expression .


and can we handle this using AS-of Table and how?

count(orderid) / count({1<DeliveryStartDateTime={"$(=date(DeliveryStartDateTime-7,'DD-MM-YYYY'))"}>}orderId)

1 Reply
MK_QSL
MVP
MVP

May be... haven't tested

count(orderid)

/

count({1<DeliveryStartDateTime={"$(=date(Max(DeliveryStartDateTime)-7,'DD-MM-YYYY'))"}>}orderId)