Page 1 of 1

Creating more records based on the day count

Posted: Tue Feb 16, 2010 2:32 pm
by sshettar
Hi All,


I have this requirement where in i am suppose to create more records than i recieve from the input file.
I have the file which has the ID , StartDT, EndDT , Location
here is a sample data of the file
100 01202010 01302010 XYZ
200 12122009 12312009 ABC
300 02012010 01282010 SGF

Now what i would want to see is for the first record the person with ID = 100 statys in the location XYZ from 01202010 through 01302010 which makes 10 days in total.
now i want to see 10 records for the ID = 100 with the date being incremented for every record and with the same location XYZ.

I'm thinking of using the transformer stage to do the looping , but not been able to succeed.

Any help on how to accomplish this task is highly appreciated

Thanks in advance

Posted: Tue Feb 16, 2010 2:49 pm
by ray.wurlod
Moderator: please move to server forum

Create a routine to generate the rows as a dynamic array. Return that and replace each dynamic array delimiter character with newline character. Write to a text file then read back from that text file.

Posted: Tue Feb 16, 2010 2:52 pm
by chulett
Much like what this FAQ posting discusses. :wink:

Posted: Wed Feb 17, 2010 7:08 am
by Sainath.Srinivasan
Or a [sparse] lookup from a calendar set