Hello Tableau experts!
I'm fairly new to Tableau and I'm currently working on a report with a connection to an OLAP cube. However, I'm getting some strange performance with some of the calculated measures that I have created.
My query at this point is very basic - I've got the order number in there, which is the lowest level of granularity and I'm filtering the data by the entry date of the current date. I've then got one measure in there, this being the net price and in total the query returns about 200 results.
I then create a calculated measure with the following formula:
CASE sign([Price Net]) when 1 then 1 else 0 end
When I then bring it into the report, it works fine and is returning the correct value in seconds. I then create the following formula, which essentially returns the same value:
IF [Price Net] <=0 then 1 else 0 end
However, the performance on this calculated field is extremely poor - it actually just ran out of memory trying to run it. Its almost as if the second formula is querying the whole cube rather than the filters dictated in the query, as opposed to the first query that just works on the filtered records.
Is there anything that we should be aware of when creating calculated measures in Tableau on a cube? I can't really see much different between the two calculations?
My experience of creating calculated measures off flat datasources would suggest that the calculation should work fine!
Thanks