Generating Multiple files in 11.3 by using sequential file

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
vamsi_4a6
Participant
Posts: 95
Joined: Wed Jun 04, 2014 12:06 am

Generating Multiple files in 11.3 by using sequential file

Post by vamsi_4a6 »

i have selected WriteMethod=Generate Multiple File for generating multiple files based on key.Job ran successfully but i do not know where the files will be created and also i do not find option to mention path for target files?
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

Possibly you're not looking in the right place, in much the same way that you're not posting this question in the correct forum.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

(sigh)

Moved.
-craig

"You can never have too many knives" -- Logan Nine Fingers
qt_ky
Premium Member
Premium Member
Posts: 2895
Joined: Wed Aug 03, 2011 6:16 am
Location: USA

Post by qt_ky »

The property where you mention the file name is no different from normal sequential file stage. You can also mention a path or use a parameter. Try it.
Choose a job you love, and you will never have to work a day in your life. - Confucius
vamsi_4a6
Participant
Posts: 95
Joined: Wed Jun 04, 2014 12:06 am

Post by vamsi_4a6 »

Thanks for Input.I can generate multiple files by using below setting

Rootfilestring-path is mentioned here
key=emp
Usevalueinfilename=True

The outpur files are generated with following names

1.part00000
2.part00000
3.part00000

but what i need is

1.txt
2.txt
3.txt
Source file
empid,empname,sal
1,a,10
2,b,20
3,c,30
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

Seems like you should enable the Exclude Partition String property.
-craig

"You can never have too many knives" -- Logan Nine Fingers
vamsi_4a6
Participant
Posts: 95
Joined: Wed Jun 04, 2014 12:06 am

Post by vamsi_4a6 »

Thanks and it is working.It is generating 3 files with name as 1,2,3.Is it possible to generate 1.txt,2.txt,3.txt without renaming the files
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

Read the documentation again. What you are requesting is not how it works (for a number of reasons). You are up for a step of renaming the files.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Post Reply