Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I need to create a list box with the values is 'Y' and 'N'.
If the sum(sales) values is 'Zero' then we need to display the values as 'N' else 'Y'.
This condition will be working to me in charts but not listbox.
Can anyone suggest how we will display the values in the listbox.
When you are saying SUM(Sales) > 0 then which dimension you are considering?
I mean Customer, Country or Product..
use below calculated dimension to create list box with Values 'Y' or 'N'
=Aggr(IF(SUM({<Customer,Sales>}Sales)>0,'Y','N'),Customer)
Replace Customer with your dimension.
You need a primary field value to fill the list box. A sum() at the outer level will aggregate everything that has been activated, and will result in either 0 or non-zero. I don't think that is what you want, correct?
You can always create a listbox with, dsay, customerID, and an expression like you specified in your post. The sum will be recalculated and produce a Y or N value for every customerID that is active (white or green).
See the Expressions tab in the Listbox Properties
It will work in the list box as well
Select list box-Go to expression -
write =if(sum(Sales)=0,'N','Y')
Hi,
If i write the expression it is showing the values in the listbox expressions. But the problem is we need to define the field for the listbox. So, in that case it is showing the data as field along with the value. But i need a list box, that contains the values only 'Y' and 'N'.
When you are saying SUM(Sales) > 0 then which dimension you are considering?
I mean Customer, Country or Product..
use below calculated dimension to create list box with Values 'Y' or 'N'
=Aggr(IF(SUM({<Customer,Sales>}Sales)>0,'Y','N'),Customer)
Replace Customer with your dimension.
Hi,
I looked at the granularity. the primary key field is 'Product Number'. Can you tell me, how we will write the expression in the list box that contains the values only 'Y' and 'N'.
if we apply above calculated condition we can get only Y or N, but he is expecting values are Y, N in the list box
@ashok1203 --try this in the script level might it will work
Hi,
By using the Manish method, I am getting the output as required. But, the problem is when i selecting value on the list box, the other value is not appearing in the Gray colour. Can you please help me on this.
What you are not getting? My solution should work. Provide sample app showing what you have done and what you are not getting..
PFA !