Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello,
I am attempting to alter an expression that currently provides data for the last 30 days to the current day. I would like to show the data for just single previous days from the current date. Below is the expression that provides the data for the last 30 days and the expression with the changes that I have attempted but will not run. Any help would be appreciated.
//count({<[Class Category ID]={0}, [Path & Area]={'People Count 1'}, [Group]={'Plaza people counting cameras'}, Date={">=$(=Date(Today()-30,'DD/MM/YYYY'))"}>} ObjectID)
count({<[Class Category ID]={0}, [Path & Area]={'People Count 1'}, [Group]={'Plaza people counting cameras'}, Date={"=$(=Date(Today(1)-30,'DD/MM/YYYY'))"} ObjectID)
Thanks
Dan
Please explain what you mean by "single previous days". Is it yesterday and today()? If so, then try this:
count({<[Class Category ID]={0}, [Path & Area]={'People Count 1'}, [Group]={'Plaza people counting cameras'}, Date={">=$(=Date(Today()-1,'DD/MM/YYYY'))"}>} ObjectID)
I am wanting to get the data for just a single day but I want to use the current day as a reference point. For example if the date is 6/6/2021 and I want just the data for 6/4/2021 the function would reference the current day minus 2 days.
Try this.
count({<[Class Category ID]={0}, [Path & Area]={'People Count 1'}, [Group]={'Plaza people counting cameras'}, Date={'$(=Date(Today()-2,'DD/MM/YYYY'))'}>} ObjectID)
It is important that your date format string 'DD/MM/YYYY' is similar to your Date field format.
Thank you, that expression did it for me.