Attributes Group By
-
- Posts: 71
- Joined: Mon Jul 20, 2009 8:52 am
- OLAP Product: TM1
- Version: 9.5 Build 9.5.00100.2380
- Excel Version: 2003
Attributes Group By
Hello,
I have a dimension called Region with a hierarchy city, country, continent. Also I have an text attribute called "population". Every city can have an entry from one of the following: "low", "medium" or "high".
Is it possible to group by this attribute in TM1-Perspective and let TM1 sum up some figures depending on the text attribute?
So e.g. I have
Medium 1000
Low 450.000
High 900.000
Thanks a lot for your help!
Toto
I have a dimension called Region with a hierarchy city, country, continent. Also I have an text attribute called "population". Every city can have an entry from one of the following: "low", "medium" or "high".
Is it possible to group by this attribute in TM1-Perspective and let TM1 sum up some figures depending on the text attribute?
So e.g. I have
Medium 1000
Low 450.000
High 900.000
Thanks a lot for your help!
Toto
-
- 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: Attributes Group By
You could create a dynamic subset for each population category listing the N level cities belonging to each attribute category. Then in a DBRW reference the subset name and TM1 will return the aggregate of the subset members (this is a hidden or undocumented feature, it has been discussed a bit on this forum in the past).
Or you could use TI to create hierarchies based on the attribute values.
Or you could use TI to create hierarchies based on the attribute values.
- jim wood
- Site Admin
- Posts: 3961
- Joined: Wed May 14, 2008 1:51 pm
- OLAP Product: TM1
- Version: PA 2.0.7
- Excel Version: Office 365
- Location: 37 East 18th Street New York
- Contact:
Re: Attributes Group By
I would use the SUBNM forumla in the report. The DBRW would then referance the result.lotsaram wrote:Then in a DBRW reference the subset name
Struggling through the quagmire of life to reach the other side of who knows where.
Go Build a PC
Jimbo PC Builds on YouTube
OS: Mac OS 11 PA Version: 2.0.7
Go Build a PC
Jimbo PC Builds on YouTube
OS: Mac OS 11 PA Version: 2.0.7
-
- 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: Attributes Group By
What do you mean? A SUBNM pulls out element(s) in the subset, but to use a subset as a user defined consolidation what you need to reference in the DBRW is the subset name itself, not the names of the elements. Am I missing something?jim wood wrote:I would use the SUBNM forumla in the report. The DBRW would then referance the result.
- jim wood
- Site Admin
- Posts: 3961
- Joined: Wed May 14, 2008 1:51 pm
- OLAP Product: TM1
- Version: PA 2.0.7
- Excel Version: Office 365
- Location: 37 East 18th Street New York
- Contact:
Re: Attributes Group By
Indeed so say if you have a list of elements on your vertical in an excel sheet you can you use subnm to pull the first, second etc...
This means that you can build a flexiable report that expands and contracts depending on the number of members in the subset.
This means that you can build a flexiable report that expands and contracts depending on the number of members in the subset.
Struggling through the quagmire of life to reach the other side of who knows where.
Go Build a PC
Jimbo PC Builds on YouTube
OS: Mac OS 11 PA Version: 2.0.7
Go Build a PC
Jimbo PC Builds on YouTube
OS: Mac OS 11 PA Version: 2.0.7
-
- 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: Attributes Group By
You guys are talking about two different things. Lotsa, you are talking about a single DBRW pulling a consolidated value from the cube with the consolidation being the subset itself. Jim is talking about a dynamic report where the rows (or columns) are dynamic based on the number of elements in the subset. Jim has to add an Excel SUM formula at the end to get the total, not to mention dealing with all the empty rows or columns you would have to build into the structure to make it work "dynamically".
- jim wood
- Site Admin
- Posts: 3961
- Joined: Wed May 14, 2008 1:51 pm
- OLAP Product: TM1
- Version: PA 2.0.7
- Excel Version: Office 365
- Location: 37 East 18th Street New York
- Contact:
Re: Attributes Group By
Not exactly difficult stuff. A simple IF statement within the DBRW cell takes care of it. I've done this many time.tomok wrote:not to mention dealing with all the empty rows or columns you would have to build into the structure to make it work "dynamically".
Struggling through the quagmire of life to reach the other side of who knows where.
Go Build a PC
Jimbo PC Builds on YouTube
OS: Mac OS 11 PA Version: 2.0.7
Go Build a PC
Jimbo PC Builds on YouTube
OS: Mac OS 11 PA Version: 2.0.7
- jim wood
- Site Admin
- Posts: 3961
- Joined: Wed May 14, 2008 1:51 pm
- OLAP Product: TM1
- Version: PA 2.0.7
- Excel Version: Office 365
- Location: 37 East 18th Street New York
- Contact:
Re: Attributes Group By
I was thinking of putting it at the top (rather than the end) to stop it moving around but hey that must just be me.tomok wrote:add an Excel SUM formula at the end to get the total
Struggling through the quagmire of life to reach the other side of who knows where.
Go Build a PC
Jimbo PC Builds on YouTube
OS: Mac OS 11 PA Version: 2.0.7
Go Build a PC
Jimbo PC Builds on YouTube
OS: Mac OS 11 PA Version: 2.0.7
-
- 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: Attributes Group By
No, not difficult, just a pain. I also forgot to mention you have to decide, in advance, how big the range should be and copy your DBRWs out to that range and add conditional formatting to make them invisible, if empty. Keep in mind I'm talking sans VBA. I generally don't use it because it means I have to have two versions, one for Excel and one for TM1Web.jim wood wrote:Not exactly difficult stuff. A simple IF statement within the DBRW cell takes care of it. I've done this many time.
- jim wood
- Site Admin
- Posts: 3961
- Joined: Wed May 14, 2008 1:51 pm
- OLAP Product: TM1
- Version: PA 2.0.7
- Excel Version: Office 365
- Location: 37 East 18th Street New York
- Contact:
Re: Attributes Group By
I agree about the range. As for formatting again that can be taken care of using IF statements rather than VBA. You just need to display null when appropriate. That's the way I've done it in the past but to be fair I haven't published them via TM1 web so I'm not sure if that would work.
Struggling through the quagmire of life to reach the other side of who knows where.
Go Build a PC
Jimbo PC Builds on YouTube
OS: Mac OS 11 PA Version: 2.0.7
Go Build a PC
Jimbo PC Builds on YouTube
OS: Mac OS 11 PA Version: 2.0.7
-
- 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: Attributes Group By
When I mentioned VBA I was talking about using it to dynamically copy the DBRW formulas down and/or across. As long as you don't care about unneccesary DBRWs then it's easy to just use conditional formatting to hide unwanted formulas. This works fine in TM1Web.jim wood wrote:I agree about the range. As for formatting again that can be taken care of using IF statements rather than VBA. You just need to display null when appropriate. That's the way I've done it in the past but to be fair I haven't published them via TM1 web so I'm not sure if that would work.
- jim wood
- Site Admin
- Posts: 3961
- Joined: Wed May 14, 2008 1:51 pm
- OLAP Product: TM1
- Version: PA 2.0.7
- Excel Version: Office 365
- Location: 37 East 18th Street New York
- Contact:
Re: Attributes Group By
Ah I get what you mean now and yes that would keep the report optimised rather than keeping a stack of unused forumlas. I guess it depends on the size of the report and how much you expect it to expand / contract.
Struggling through the quagmire of life to reach the other side of who knows where.
Go Build a PC
Jimbo PC Builds on YouTube
OS: Mac OS 11 PA Version: 2.0.7
Go Build a PC
Jimbo PC Builds on YouTube
OS: Mac OS 11 PA Version: 2.0.7