Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Did Set Analysis syntax change in v12?
This simple expression evaluates as bad in v12.10 SR4 and evaluations as good in v11.20 SR9.
Where vInc.OpenPO is set in the Settings / Variables to Year = {'2017'}
When I change the expression to =Sum({< Year = {'2017'} >} Value) in v12, the expression evaluates as correct.
Puzzled,
John
This is bug in v12.10 SR4. But, Output will give same as i noticed earlier. 11.20 is considering as Expression but QV12 get it as simple expression with error. They are working on it for next release version
This is bug in v12.10 SR4. But, Output will give same as i noticed earlier. 11.20 is considering as Expression but QV12 get it as simple expression with error. They are working on it for next release version
Anil,
thanks for the response and confirmation that it is a bug.
Then close this thread by Flag Correct Answer
However, when using my production expression, I do not get the right answer.
This expression, which uses $(vInc.OpenPO) in the set analysis, returns a null()
=IF(vCurrencyType = 'USD',
Num(IF(vShowOpenPO = 1,
Sum(EntryValue)+Sum( {< $(vInc.OpenPO) >} POAmount ),
Sum(EntryValue)),'$#,##0.00;($#,##0.00)'),
IF(vCurrencyType = 'EUR',
Num(IF(vShowOpenPO = 1,
Sum(EntryValue)+Sum({<$(vInc.OpenPO)>}POAmount),
Sum(EntryValue)),'€#,##0.00;(€#,##0.00)'),
Num(IF(vShowOpenPO = 1, // if not USD or EUR, display w/out a currency symbol
Sum(EntryValue)+Sum({<$(vInc.OpenPO)>}POAmount),
Sum(EntryValue)), '#,##0.00;(#,##0.00)')
)
)
This expression, where I've replaced $(vInc.OpenPO) in the set analysis with POStatus = {'Open'}, gives the expected values.
=IF(Currency = 'USD',
Num(IF(vShowOpenPO = 1,
Sum(EntryValue)+Sum({< POStatus = {'Open'} >} POAmount ),
Sum(EntryValue)),'$#,##0.00;($#,##0.00)'),
IF(Currency = 'EUR',
Num(IF(vShowOpenPO = 1,
Sum(EntryValue)+Sum({<POStatus = {'Open'} >}POAmount),
Sum(EntryValue)),'€#,##0.00;(€#,##0.00)'),
Num(IF(vShowOpenPO = 1, // if not USD or EUR, display w/out a currency symbol
Sum(EntryValue)+Sum({<POStatus = {'Open'}>}POAmount),
Sum(EntryValue)), '#,##0.00;(#,##0.00)')
)
)
What's the definition you have written for the
vInc.OpenPO?
in the variable definition just write
POStatus = {'Open'} or 'POStatus = {'Open'}'
without = sign , then should work
The variable defn is POStatus = {'Open'}
And it does not work. As Anil mentioned, this is a bug in v12.10 SR4. He said that the expression should give the correct results. While it does in my simple test app, it fails when using the above.
Note that this works just fine in v11.20 SR9.
edited; I was able to confirm that the expression does work as expected. This bug is just in the syntax check.