Hi there,
Happy New Year !
I have a situation here, and would like to seek for your opinion.
I have total of 13 files, loading into the same cube. With the differences, load into different Country, different Currency.
I'm thinking which way would be the better way to do this. I can either to have 13 differnt TI processes, or to have 1 single TI process, and let the user trigger the input (eg load the file 1 by 1).
Is there any other better way that I can do ?
The file I'm loading is Actual numbers for multiple countries, multiple currencies. The problem is that inside the dat file, there's no country nor the currency information. This is found only with the filename.. this is exactly why there are multiple files..
Has anyone have similar situation before? Can share with me?
Loading multiple files into a cube
-
- Community Contributor
- Posts: 341
- Joined: Wed Nov 03, 2010 9:16 pm
- OLAP Product: tm1
- Version: 10 2 2 - 2.0.5
- Excel Version: From 2007 to 2013
- Location: Earth
Re: Loading multiple files into a cube
Hi
Or, you can write a simple 'master' TI that calls your original TI using ExecuteProcess 13 times with the file name, countries and currencies as parameters.
You can also embed the ExecuteProcess calls into a WHILE loop in the 'master' if you can find an algorithm for that (e.g. cycling through the elements in the country and currency dimensions).
Yes, this is a possible solution, in this case the user has to run the TI 13 times.or to have 1 single TI process, and let the user trigger the input (eg load the file 1 by 1)
Or, you can write a simple 'master' TI that calls your original TI using ExecuteProcess 13 times with the file name, countries and currencies as parameters.
You can also embed the ExecuteProcess calls into a WHILE loop in the 'master' if you can find an algorithm for that (e.g. cycling through the elements in the country and currency dimensions).
-
- Posts: 63
- Joined: Wed Sep 14, 2011 3:10 am
- OLAP Product: TM1
- Version: PA 2.0
- Excel Version: Office 365
Re: Loading multiple files into a cube
Hi ,
THanks for suggestion. Can you tell me how can I pass in the filename as parameter, which in turn to be a data source for another TI process? Or maybe I can write a bat file, which is to be executed in a WHILE loop, which then copies the 1st dat file into a common .txt file, which this .txt file is the data source of the child TI, which will be called by the master TI..
Is this what you are suggesting?
THanks for suggestion. Can you tell me how can I pass in the filename as parameter, which in turn to be a data source for another TI process? Or maybe I can write a bat file, which is to be executed in a WHILE loop, which then copies the 1st dat file into a common .txt file, which this .txt file is the data source of the child TI, which will be called by the master TI..
Is this what you are suggesting?
-
- Site Admin
- Posts: 6667
- Joined: Sun May 11, 2008 2:30 am
- OLAP Product: TM1
- Version: PA2.0.9.18 Classic NO PAW!
- Excel Version: 2013 and Office 365
- Location: Sydney, Australia
- Contact:
Re: Loading multiple files into a cube
I'd point you to the manual for this but the TI manual is frapping awful when it comes to explaining how to create DIY processes.beek wrote: THanks for suggestion. Can you tell me how can I pass in the filename as parameter, which in turn to be a data source for another TI process?
This will only really work if all 13 files have the same columns. If they do, create a dummy file (one with the same structure as the real files and with at least a few rows of realistic data), and set that as your file source on the Data Source tab of a new process. This is only to allow you to work with something while you're writing your code; you can delete it when you're done.
Write the processing code on the Metadata and Data tabs as normal.
Now go to the Advanced tab, and go to the Parameters sub-tab below that.
Over on the right you will see a button titled [Insert] which allows you to add a parameter. The parameter can be either string or numeric. In your case you'll want it to be a string. This will be used to receive your filename. In all other respects it acts like a normal variable.
Set the DataSourceNameForServer process variable to the value of your parameter in the Prolog tab. In this way every time the process is called, it will reassign the data source name to the value passed in to that parameter.
You're on the right track but there's no need to mess around with batch files.beek wrote:Or maybe I can write a bat file, which is to be executed in a WHILE loop, which then copies the 1st dat file into a common .txt file, which this .txt file is the data source of the child TI, which will be called by the master TI..
Is this what you are suggesting?
Create a second process which is the Master process referred to in the earlier post. In the prolog tab you create a While loop to call the original process 13 times. Each call will be made using the ExecuteProcess TI function, which allows you to pass parameters to the called process. See the help example via that link to see how that's done.
"To them, equipment failure is terrifying. To me, it’s 'Tuesday.' "
-----------
Before posting, please check the documentation, the FAQ, the Search function and FOR THE LOVE OF GLUB the Request Guidelines.
-----------
Before posting, please check the documentation, the FAQ, the Search function and FOR THE LOVE OF GLUB the Request Guidelines.
-
- Posts: 63
- Joined: Wed Sep 14, 2011 3:10 am
- OLAP Product: TM1
- Version: PA 2.0
- Excel Version: Office 365
Re: Loading multiple files into a cube
BIG thank you Alan. I understand now. will try that out ..
cheers,

cheers,
-
- 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: Loading multiple files into a cube
"BIG thank you Alan. I understand now. will try that out ..
If you figured it out ,Could you please share the script.Thanks

If you figured it out ,Could you please share the script.Thanks
"You Never Fail Until You Stop Trying......"
-
- Site Admin
- Posts: 6667
- Joined: Sun May 11, 2008 2:30 am
- OLAP Product: TM1
- Version: PA2.0.9.18 Classic NO PAW!
- Excel Version: 2013 and Office 365
- Location: Sydney, Australia
- Contact:
Re: Loading multiple files into a cube
You do realise that the actual script will be completely different for everyone depending on the structure of their cubes, the data in their files, etc,, yes? You won't be able to take the OP's TI process and run it on your own cubes.BariAbdul wrote:"BIG thank you Alan. I understand now. will try that out ..![]()
If you figured it out ,Could you please share the script.Thanks
The part of the process that relates to calling a second process repeatedly and having it process a different file each time is already described above, with links to the corresponding parts of the manual. The rest is going to be specific to your own setup.
"To them, equipment failure is terrifying. To me, it’s 'Tuesday.' "
-----------
Before posting, please check the documentation, the FAQ, the Search function and FOR THE LOVE OF GLUB the Request Guidelines.
-----------
Before posting, please check the documentation, the FAQ, the Search function and FOR THE LOVE OF GLUB the Request Guidelines.