Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi ,
I have a requirement where I have to show two markets: all products in first market and in second market all products except two.
I tried this but didnt work.
if(Brand_Market='NS Range',Brand_Product) and if(Brand_Market='Gilenya Market',if(not match(Brand_Product,'Gilenya','Mayzent'),Brand_Product))
Thanks in advance
Perhaps something along the lines of:
if(Brand_Market='NS Range' OR (Brand_Market = 'Gilenya Market' and not match(Brand_Product,'Gilenya','Mayzent')),Brand_Product)
Assuming you prefer this as an if() rather than set analysis.
HI,
Thanks for your reply. I would prefer to limit in dimension because using set analysis in expression would be too long. BUt this expression doesnt work
Thanks
I tested this using inline data and it works as expected when used as a measure. In your scenario, the specific data structure / context may not allow this to be used as a calculated dimension, in which case you will likely have to use aggr() to work around that.
Note that this is not a recommended approach in general. It would be better for performance to create this field in your script (using the formula already provided) and then using that field as your dimension:
Load *, if(Brand_Market='NS Range' OR (Brand_Market = 'Gilenya Market' and not match(Brand_Product,'Gilenya','Mayzent')),Brand_Product) as Brand_Product_For_Chart
From YourTable;
Hi,
Thanks for you reply! The requirement is changed and I need to modify the question a bit . If I select Brand_Market='NS Range', products of NS Range and products of Gilenya Market excluding the two products must be visible. For other markets, as usual all corresponding brand prodcuts must be visible.
Quick response is appreciated.
Thanks in advance