Changing element name
-
- Regular Participant
- Posts: 424
- Joined: Sat Mar 10, 2012 1:03 pm
- OLAP Product: IBM TM1, Planning Analytics, P
- Version: PAW 2.0.8
- Excel Version: 2019
Changing element name
This might be quite easy one TM1 gurus,I need to change an element name in the model,I know I need to create an alias and simply use the TI function: SwapAliasWithPrincipalName(DimName,AiasName,Flag) in prolog.
But my question is, this particular element has been refrenced widely in rules with other cubes.Is there any chance of something going amiss if I change the element name.Thanks
But my question is, this particular element has been refrenced widely in rules with other cubes.Is there any chance of something going amiss if I change the element name.Thanks
"You Never Fail Until You Stop Trying......"
- 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: Changing element name
I'm sur ethis is something that is easily done these in PM, but in earlier version it was a task. From what I know of PM it will simply run TI's in the background. For rules it will depend I guess on how they are defined, if they are link / dimension calculations setup in PM you're probably good. Any manual calculations added will probably be another question entriely,
Jim.
Jim.
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
-
- Regular Participant
- Posts: 424
- Joined: Sat Mar 10, 2012 1:03 pm
- OLAP Product: IBM TM1, Planning Analytics, P
- Version: PAW 2.0.8
- Excel Version: 2019
Re: Changing element name
Thanks for the reply Jim,unfortunately I am on 9.5.2 so PM is out of question , as I mentioned before there are quite a few rules written across the cubes on this element,is there any workaround to this,Please! Thanks
"You Never Fail Until You Stop Trying......"
-
- 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: Changing element name
Your only option is to use a text editing tool against the .rux files for a search and replace. I'm partial to Notepad ++ but there are other tools that function just as well. 1) Go to the data folder and open all the .rux files, 2) search and replace, delete all the .blb files where all the characters on the left hand side of the dot (".") equal the cube name (these files are rules formatting files), 3) recycle the server.
-
- Regular Participant
- Posts: 424
- Joined: Sat Mar 10, 2012 1:03 pm
- OLAP Product: IBM TM1, Planning Analytics, P
- Version: PAW 2.0.8
- Excel Version: 2019
Re: Changing element name
Thanks a lot Tomok,Appreciate your help.
"You Never Fail Until You Stop Trying......"
- gtonkin
- MVP
- Posts: 1269
- Joined: Thu May 06, 2010 3:03 pm
- OLAP Product: TM1
- Version: Latest and greatest
- Excel Version: Office 365 64-bit
- Location: JHB, South Africa
- Contact:
Re: Changing element name
You could also try using SED (command line tool)
You need to use notepad to create an input file for SED to process - call it rename.sed for example then enter in
I then use a batch file to execute through the various file types:
I would recommend a solid back-up and double-and triple checking once run.
You may need to add multiple lines in rename.sed for mutiple search and replaces. Also keep in mind that the example is case sensitive - there may be parameters you can pass to search and replace without considering case.
You could/should also copy the FOR section multiple time, one for BLB, RUX and PROs
Read carefully and use at your own risk once you have understood the process - if incorrectly used, you could end up with a whole lot of zero sized files
You need to use notepad to create an input file for SED to process - call it rename.sed for example then enter in
Code: Select all
s/\OLDNAME/NEWNAME/g
Code: Select all
@echo off
set currdir=%CD%
echo %currdir%
for /R %%D in (.) do (
echo %%D
cd %%D
for /F "tokens=*" %%F in ('dir *.rux /b') do ( echo %%F
sed -f %currdir%\rename.sed "%%F" >temp
move /Y temp "%%F" >nul
)
cd ..
)
You may need to add multiple lines in rename.sed for mutiple search and replaces. Also keep in mind that the example is case sensitive - there may be parameters you can pass to search and replace without considering case.
You could/should also copy the FOR section multiple time, one for BLB, RUX and PROs
Read carefully and use at your own risk once you have understood the process - if incorrectly used, you could end up with a whole lot of zero sized files
- Attachments
-
- Rename.zip
- Sample files
- (39.76 KiB) Downloaded 333 times
-
- Regular Participant
- Posts: 152
- Joined: Sat May 25, 2013 10:32 am
- OLAP Product: TM1
- Version: 9.5.2; 10.2.2
- Excel Version: 2007
Re: Changing element name
Tomok reply is nice 
You can try with Advance Rules Editor for search and replace. Which will not require deletion of .blb files.
Regards,
Deepak Jain

You can try with Advance Rules Editor for search and replace. Which will not require deletion of .blb files.
Regards,
Deepak 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: Changing element name
Indeed you can but you have to do each rule file one by one. With Notepad ++ you can open all the files at once and do just one search and replace. Much more efficient.deepakjain2020 wrote:You can try with Advance Rules Editor for search and replace. Which will not require deletion of .blb files.
-
- Regular Participant
- Posts: 152
- Joined: Sat May 25, 2013 10:32 am
- OLAP Product: TM1
- Version: 9.5.2; 10.2.2
- Excel Version: 2007
Re: Changing element name
Thanks Tomok. That's good one 
