We have a product dimension containing products from many countries. We have an attribute on every product that tell us which country the product belong to.
I want to filter out and keep all products from a specific country, and still keep the product hierarchy.
Example:
Product level 1 - Country (null)
Product Car - Country US
Product Ball - Country Sweden
When I use "Filter by attribute", and filter "US", the Product Ball and the Product level 1 disappear. This is not strange because I have no country on Product level 1. But I cant't set the country on the hierarchy levels because I can have products from different countries belonging to the same level in the hierarchy.
Do you know how I can filter on attribute and keep my product hierarchy unchanged?
When I filter US I want the result to be:
Product level 1 - Country (null)
Product Car - Country US
Thanks!
/Sverker
Filter on attribute and keep the hierarchy
-
- Community Contributor
- Posts: 132
- Joined: Thu Oct 15, 2009 7:45 pm
- OLAP Product: TM1
- Version: 9.4.1 9.5 9.5.1
- Excel Version: 2003 2007
Re: Filter on attribute and keep the hierarchy
filter by attribute looks for the exact value that you entered for the filter. This is why it gets rid of Product level 1.
If a product can only be assigned to 1 country why not create a hierarchy.
Product level1
-> US
--> Car
-> Sweden
--> Ball
If a product can be part of multiple countries, then you can create separate dimension.
If a product can only be assigned to 1 country why not create a hierarchy.
Product level1
-> US
--> Car
-> Sweden
--> Ball
If a product can be part of multiple countries, then you can create separate dimension.
Ankur Jain
-
- MVP
- Posts: 2836
- Joined: Tue Feb 16, 2010 2:39 pm
- OLAP Product: TM1, Palo
- Version: Beginning of time thru 10.2
- Excel Version: 2003-2007-2010-2013
- Location: Atlanta, GA
- Contact:
Re: Filter on attribute and keep the hierarchy
One idea would be to create a separate attribute for each country, i.e. US, CAD, GB, etc., instead of a single "country" attribute, and make the attribute numeric. Then all you have to do is filter on values greater than zero for the country in question as Product level 1 will be >=1 if any of it's children have been flagged for that country. It's a little messy because it requires multiple attributes instead of one but it works and it is easy to understand.svgu wrote:Do you know how I can filter on attribute and keep my product hierarchy unchanged?
-
- MVP
- Posts: 3706
- Joined: Fri Mar 13, 2009 11:14 am
- OLAP Product: TableManager1
- Version: PA 2.0.x
- Excel Version: Office 365
- Location: Switzerland
Re: Filter on attribute and keep the hierarchy
I'm not sure I follow. Numeric attributes, as discussed often on this forum, are really just "strings disguised as numbers". Numeric attributes don't consolidate, so even if the children of a parent have populated numeric attributes the same attribute for the parent will still be zero unless it has been explicitly populated.tomok wrote:One idea would be to create a separate attribute for each country, i.e. US, CAD, GB, etc., instead of a single "country" attribute, and make the attribute numeric. Then all you have to do is filter on values greater than zero for the country in question as Product level 1 will be >=1 if any of it's children have been flagged for that country. It's a little messy because it requires multiple attributes instead of one but it works and it is easy to understand.
The only way to make this method work would be to hold the numeric 1/0 Boolean country flags in a separate 2D lookup cube and populate the attribute values by a rule referencing the lookup cube.
-
- MVP
- Posts: 2836
- Joined: Tue Feb 16, 2010 2:39 pm
- OLAP Product: TM1, Palo
- Version: Beginning of time thru 10.2
- Excel Version: 2003-2007-2010-2013
- Location: Atlanta, GA
- Contact:
Re: Filter on attribute and keep the hierarchy
I guess wasn't explicit enough. Yes, I was talking about a user generated attrbute cube. That's just second nature to me because I use this type of cube for attributes more often than the }ElementAttributes kind.lotsaram wrote:The only way to make this method work would be to hold the numeric 1/0 Boolean country flags in a separate 2D lookup cube and populate the attribute values by a rule referencing the lookup cube.