how to load file dynamically with dynamic column order

Post Reply
kpradeep25
Posts: 18
Joined: Mon May 09, 2011 3:09 pm
OLAP Product: TM1
Version: 9.4
Excel Version: EXCEL 2003

how to load file dynamically with dynamic column order

Post by kpradeep25 »

Hi,

Wonder if this can be achieved in TI. I have a requirement to load files where order and number of column changes everytime the new file arrives.I only need to load some columns from the file, these columns can be selected by column title. when I try to achieve this using formula TI process fails because TI searches column in the the fixed order . Can anyone please provide any idea how to achieve this.

Need to load only these three columns:

emp no, address and salary

from:

File 1:
emp name, dept no, salary, address

File 2:

dept no, emp name, address, salary
tomok
MVP
Posts: 2832
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: how to load file dynamically with dynamic column order

Post by tomok »

The only way I know of would be to have each column named generically in the TI and then in the file have a first record for each column that indicates what is in the column. Create a variable in the Prolog tab for each column. Then in the DATA tab you could keep a record count and if this is the first record, check the values in each column to find out what is in each. Then set a value for the variables created in the Prolog tab. Then in the Data tab, for records 2 thru whatever, you can use a series of IF statemements (looking at the values in the variables created to tell what is in the columns) to create the CellPut formulas. Good luck. Very bad design BTW.
Tom O'Kelley - Manager Finance Systems
American Tower
http://www.onlinecourtreservations.com/
ajain86
Community Contributor
Posts: 132
Joined: Thu Oct 15, 2009 7:45 pm
OLAP Product: TM1
Version: 9.4.1 9.5 9.5.1
Excel Version: 2003 2007

Re: how to load file dynamically with dynamic column order

Post by ajain86 »

Ankur Jain
kpradeep25
Posts: 18
Joined: Mon May 09, 2011 3:09 pm
OLAP Product: TM1
Version: 9.4
Excel Version: EXCEL 2003

Re: how to load file dynamically with dynamic column order

Post by kpradeep25 »

Thanks Tom and Ankur - I will try these.
Post Reply