Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello i need to know if is anything wrong in this expression, it doesn't return me the expected values:
Count({<[FIELD A]={"=$([FIELD A])-1"}}DISTINCT [FIELD B])
Thanks
Marco
I think this only works when you select 1 value in FIELD A
=Count({<[FIELD A]={"$(=([FIELD A])-1)"}>}DISTINCT [FIELD B])
maybe
=Count({<[FIELD A]={"$(=max([FIELD A])-1)"}>}DISTINCT [FIELD B])
but it's still not clear what do you want to achieve
The reason that this doesn't work is that set analysis is evaluated outside of a chart to reduce/expand the data rows that go into the chart. This evaluation happens before any calculation is performed.
The logical consequence, as Massimo already pointed out, is that -1 will return all currently selected values in field and then try to subtract 1 from that result. Which only works if you select a single value in .
Set analysis does not work row-by-row, but globally for all data used in a chart.
Peter
Oh and by the way: for a single value you better use something like ...{'$(=-1)'}
But this is different than what pcammaert has suggested, try single quote as suggested. But restrict selection of single value only in list box.
I have tried but it is still not working.
Any other ideas?
Thanks
Marco
I have tried with this statement using the above but it still not working:
=Count(DISTINCT {< = {"=$(above())"}>})
Where A is a dimension of the table and B is an expression.
The above works fine but if used within the expression doesn't work.
Thanks
Marco
Hello, anybody knows what's wrong about this formula?
=Count({< [year = {"=$(=Num(above([year]),'0'))"}>}distinct [object])
I need to count the sum of object of a previous year.
For me this is correct infact the Num(above([year]),'0') works, but not if inserted in the Count expression.
Thanks
Marco
I think there are some syntax error, this should be ok from a syntax point of view
=count( {$ <year={"$(=above(year))"}>} distinct object)
but I'm not sure above and set analysis together make sense (above is an inter record function, set analysis is calculated once for chart)
what do you want to achieve?
count distinct object when the year is ....???
I need to get the sum comparison between one year row and the above, that could not be sequentially.
Used singularly the above works perfectly, but not in the expression.
Is it possible to write a formula in order to get a value like this?
Thanks
Marco