Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello,
I have two time fields, and want to use set analysis to set time1 >= (time2 minus 3 months). Is this possible? I have attempted this and have not had any luck. My attempt is below.
=count({$<Time1={"=Time1>=AddMonths(Time2,-3)"}>} Distinct OrderID)
Any help would be appreciated.
Thanks Much!
Hello,
try
=count({<Time1>=$(=AddMonths(...))>} distinct OrderID)
The trick is, to embrace the expression in $(). This makes QV to evaluate the expression.
hth,
Thilo
Sorry ... too quick reply ... I checked my own code now ... I use it like this:
SUM( {<DateDMY={'>=$(=AddMonths(monthstart(max(DateDMY)),PeriodMonths)) <=$(=monthend(max(DateDMY)))'} >} Value)
First, thanks for the response.
However It seems that you only refer to one time field (DateDMY) in your expression.
I actually want to evaluate where DateDMY >= Date2DMY-3 months. So I have two separate date fields in total in the expression. Hopefully this makes sense
Regards.