Logic to generate output files dynamically

Post questions here relative to DataStage Enterprise/PX Edition for such areas as Parallel job design, Parallel datasets, BuildOps, Wrappers, etc.

Moderators: chulett, rschirm, roy

Post Reply
Developer9
Premium Member
Premium Member
Posts: 187
Joined: Thu Apr 14, 2011 5:10 pm

Logic to generate output files dynamically

Post by Developer9 »

Hi ,
I have a requirement to generate output files based on the division Grouping populated in a table (group numbers subject to change depends on change in the data)

Code: Select all

Group| Division
1	5
2	5
3	5
N   5
1	25
2	25
3	25
4	25
5	25
6	25
7	25
Output :

Code: Select all

Division 5-File 1,File 2 ,File3 ..FileN
Division 25-File1,File2,..File7
Design Tested

Code: Select all

File/Table (read group,division) --->filter criteria (division,group) -->file1,file2 ..fileN
This will be only work if Group numbers are constant but for dynamic group numbers how can we implement logic to split files

Please let me know your ideas to implement logic for this scenario
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

Code: Select all

[/b] tags, not [b][quote][/b] tags for things of this nature. Fixed for you.
-craig

"You can never have too many knives" -- Logan Nine Fingers
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

Upgrade to at least 9.1 and that functionality is built into the Sequential File stage. :wink:
-craig

"You can never have too many knives" -- Logan Nine Fingers
Developer9
Premium Member
Premium Member
Posts: 187
Joined: Thu Apr 14, 2011 5:10 pm

Post by Developer9 »

@Chulett,

At my place we might move to 11.5 but not immediately until then I need to build the logic in place to support this task.

Thanks
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

Use a server job and the Folder stage. If you are required by internal politics only to have parallel jobs, put the Folder stage in a server Shared Container and use that Shared Container in your parallel job. The Folder stage has the capability you are seeking.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Developer9
Premium Member
Premium Member
Posts: 187
Joined: Thu Apr 14, 2011 5:10 pm

Post by Developer9 »

Thank you all for the input ..There was a requirement change holding off my testing ..still want to test this scenario :) I am creating a new post for the new requirement :)
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

Your Moderator thanks you.
-craig

"You can never have too many knives" -- Logan Nine Fingers
Post Reply