SwapAliaswithPrincipalName old name in sub and vue files

Post Reply
User avatar
vovanenok
Posts: 88
Joined: Mon Jun 23, 2014 4:54 pm
OLAP Product: TM1
Version: 2.0.9
Excel Version: Office 365
Location: Toronto, Canada
Contact:

SwapAliaswithPrincipalName old name in sub and vue files

Post by vovanenok »

Hi all

I'm playing with SwapAliaswithPrincipalName, in particular I want to test how the new name works in subsets and views
My scenario:
1. Created 1 public subset, 1 private subset, 1 public view, 1 private view
2. Set a TempAlias for my test element
3. Ran a process calling SwapAliaswithPrincipalName and deleting TempAlias after
4. Restarted TM1 server
5. Checked the element was renamed correctly
6. Checked the element showed up in the subsets and views I created previously.
7. Checked sub files: the old name is still there
8. Checked vue files: the old name is still there
9. Checked all the aliases (to make sure the old name was not left anywhere)
10. Tried to Copy-Paste the old name in dimension subset editor, result > element not found.

Even though the new name works fine in subsets and views (I'm still going to do a few tests with data), I'm concerned about the old name in sub and vue files.

Does anybody have experience using SwapAliaswithPrincipalName in PROD?
What do you think about sub and vue files? How come they contain the old element name and it works when opening in Architect?
----------
TeamOne Google Sheets add-on for IBM Planning Analytics
Let's connect on LinkedIn
tomok
MVP
Posts: 2831
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: SwapAliaswithPrincipalName old name in sub and vue files

Post by tomok »

I'm pretty sure that the function SwapAliaswithPrincipalName is not smart enough to cycle through all your views and subsets and change them. All it does it update the dimension. You're on your own to figure out the best way to update the .sub and .vue files.
Tom O'Kelley - Manager Finance Systems
American Tower
http://www.onlinecourtreservations.com/
User avatar
vovanenok
Posts: 88
Joined: Mon Jun 23, 2014 4:54 pm
OLAP Product: TM1
Version: 2.0.9
Excel Version: Office 365
Location: Toronto, Canada
Contact:

Re: SwapAliaswithPrincipalName old name in sub and vue files

Post by vovanenok »

Thanks Tom. That was the first thing I thought of. The mystery is those subsets and views perfectly display the new element name after the server restart so somehow TM1 translates the old to new name when loading those sub and vue files on startup
----------
TeamOne Google Sheets add-on for IBM Planning Analytics
Let's connect on LinkedIn
User avatar
vovanenok
Posts: 88
Joined: Mon Jun 23, 2014 4:54 pm
OLAP Product: TM1
Version: 2.0.9
Excel Version: Office 365
Location: Toronto, Canada
Contact:

Re: SwapAliaswithPrincipalName old name in sub and vue files

Post by vovanenok »

One more observation. I opened }ElementAttributes_MyTestDim.cub file in Notepad++ (yes I know .cub are binary files and are not supposed be viewed in a text editor), but among all the not recognized content I can see my TestElementOldName.
The same is for MyTestDim.dim file, I can see both TestElementNewName and TestElementOldName inside that dim binary file.

This explains why TM1 can correctly load sub and vue files so they contain the new element name.
But it bring more concerns about using SwapAliaswithPrincipalName.

One more test:
1. Right-click MyTestDim in Architect > Edit Dimension Structure
2. Insert a new element with name = TestElementOldName
3. Save dimension changes
4. Check my subsets and views, they still correctly show the new element name
5. Open MyTestDim.dim file in Notepad++ and now it shows TestElementOldName twice

Looks like SwapAliaswithPrincipalName messed up the .dim file
----------
TeamOne Google Sheets add-on for IBM Planning Analytics
Let's connect on LinkedIn
Post Reply