Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I have a set expression where I would like to count the value if the last value in time has service_activity.action 1 or 2.
The problem is how to make sure it is only the latest value that is checked?
=count ({$< service_activity.createtime={"$(=Max(service_activity.createtime))"}, service_activity.action={"2"} >+< service_activity.action={"1"} >} service_activity.subscription_id )
If I have the following:
service_activity.createtime service_activity.action service_activity.subscription_id
2012-01-01 2 A
2013-01-01 1 A
2014-01-01 5 A
I get my expression to calculate 1, when I want 0. I only want to check whether the latest value (2014-01-01) is 1 or 2.
How can I do this?
Many thanks.