Hello All,
Is there any way, in websheet, a filter will get populated based on User login. For example, Let say User A is associated with Canada Country and User B in associated with North America, now when user get into websheet, For A, country filter must show Canada as default selection and hence all data asscoiated with that country, and whn user B goes in, he/she must see North America selected as default country and hence all data populated in websheet for that country.
Since i am new in TM1, so might be my query is a silly one, but still if you guys help me on achieving this requirement, that would be great help.
Thanks,
Manoj
Default Selection in websheet based on user login
- qml
- MVP
- Posts: 1098
- Joined: Mon Feb 01, 2010 1:01 pm
- OLAP Product: TM1 / Planning Analytics
- Version: 2.0.9 and all previous
- Excel Version: 2007 - 2016
- Location: London, UK, Europe
Re: Default Selection in websheet based on user login
Yes, there are quite a few ways of achieving this. A few off the top of my head:
One would be to apply element security to the country dimension and use SUBNM() with a reference to a generic subset. Since everyone will only be able to see their elements in the subset, referencing, say, element number 1 in the subset will return a different element for each person, based on their security settings.
Another option would be to create named subsets (one for each user) with users' logins preferably constituting a part of these subsets' names. Then using the TM1USER() worksheet function you can figure out in the websheet who the user is and using an excel formula build a reference to the named subset within SUBNM(). The most convenient way to maintain these subsets is to have a TI process that cycles through all users, picks up their default country from somewhere (e.g. a lookup cube or an attribute of the }Clients dimension) and (re)creates all subsets based on this.
Another way would be to create a config cube with picklists. These picklists could be personalised in a static way (the cube would have to contain the }Clients dimension) or using rules based on the TM1USER() function. This is the most advanced approach, so you're probably better off looking at the simpler solutions above.
Maybe someone else can suggest some other approach, I'm sure there are a few others.
One would be to apply element security to the country dimension and use SUBNM() with a reference to a generic subset. Since everyone will only be able to see their elements in the subset, referencing, say, element number 1 in the subset will return a different element for each person, based on their security settings.
Another option would be to create named subsets (one for each user) with users' logins preferably constituting a part of these subsets' names. Then using the TM1USER() worksheet function you can figure out in the websheet who the user is and using an excel formula build a reference to the named subset within SUBNM(). The most convenient way to maintain these subsets is to have a TI process that cycles through all users, picks up their default country from somewhere (e.g. a lookup cube or an attribute of the }Clients dimension) and (re)creates all subsets based on this.
Another way would be to create a config cube with picklists. These picklists could be personalised in a static way (the cube would have to contain the }Clients dimension) or using rules based on the TM1USER() function. This is the most advanced approach, so you're probably better off looking at the simpler solutions above.
Maybe someone else can suggest some other approach, I'm sure there are a few others.
Kamil Arendt
-
- 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: Default Selection in websheet based on user login
Using element security to call a subset element by index and having a separate country by user will work providing users have access to a unique country. If users have access to several countries it might not work so well.
Another option would be to have a cube with the clients dimension and a string measure to hold a default country selection per user. Then in the websheet use a combination of the TM1User function and a DBR to the cube holding the default selection in place of a SUBNM for a title element. I have used this approach many times and it works well.
Another option would be to have a cube with the clients dimension and a string measure to hold a default country selection per user. Then in the websheet use a combination of the TM1User function and a DBR to the cube holding the default selection in place of a SUBNM for a title element. I have used this approach many times and it works well.
-
- Posts: 60
- Joined: Thu Mar 17, 2011 2:13 pm
- OLAP Product: IBM Cognos TM1
- Version: 10.2.1
- Excel Version: 2010
Re: Default Selection in websheet based on user login
Thanks a lot.
If Possible, can you please send me the code, which you used for dynamic selection based on user login.
Thanks a lot
Manoj
If Possible, can you please send me the code, which you used for dynamic selection based on user login.
Thanks a lot
Manoj