Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I have a simple table with four products:
Products A and B are very important to my users, so they should be shown in a table on their own. There is also a filter allowing a user to select a product:
The measure in the table is calculated as: Sum({<Name*={'A', 'B'}>} Value)
This is so that the table shows records for A and B when they are selected or possible. But if a user selects a Product that is not A or B, then nothing should be shown.
This works ok when A and B are selected or possible e.g.:
But it show this when I select Product C:
In this case I want to see no rows in the table - A and B are not selected so my users don't want to see any data.
I know I could turn off 'Include zero values' in Data Handling but this is a problem if the value for A or B is 0. E.g. if the value for A is 0, it's important for my users to see this - they need to know that A has 0 value.
I feel like there is an obvious solution to this problem but I can't think what it is. Any ideas?
did you try unchecking include nulls under your dimension NAME? or you can try this
if(not match(NAME,'A','B'),null(),Sum({<Name={'A', 'B'}>} Value))
Thanks for the suggestion. However I get this:
'Include null values' doesn't make a difference
then try this
in dimension create
if(match(NAME,'A','B'),NAME)
remove set analysis from expression(redundant)
and uncheck include null values
Thanks for your response but unfortunately this doesn't work:
Include null values is unchecked
Hi there
Try making Name your Dimension and make your measure this:
Sum({<Name=,Name={'A','B'}>} Value)
Regards,
Mauritz
Thanks for your suggestion. Unfortunately this doesn't work as when I select Product C in the filter box, Product A and B are displayed in the table. I need the table to be blank (with no records displayed) when the selected product is not A or B
Hi,
section access; is the best solution to your visualization, you can control what ever you want.
and as your way it will work (Exclude selections will not displayed in selection and table)
Example:
section access;
load * inline [
ACCESS, USERID, PRODUC_ID
ADMIN, \matr, *
USER, \matr, C
USER, \report, D
];
SECTION APPLICATION;
K. Srinivasan.
Hi,
try with this expression
Sum({<Name*={'A', 'B'}>} Value+0.001)
suppress 0 values and set format number, so it will show 0 and not 0.001
i have tried, but
it has shows 0.001 value for A, B
same old status continue for C and D same :
K. Srinvasan