Output file naming convention

A forum for discussing DataStage<sup>®</sup> basics. If you're not sure where your question goes, start here.

Moderators: chulett, rschirm, roy

Post Reply
qt_ky
Premium Member
Premium Member
Posts: 2895
Joined: Wed Aug 03, 2011 6:16 am
Location: USA

Post by qt_ky »

You could generate whatever values you need to in a User Variables stage of a Sequence job, perhaps using an Oconv() function.
Choose a job you love, and you will never have to work a day in your life. - Confucius
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

If your 'running number' needs to be incremented each time the job runs, store it in a sequence of some kind. Increment it when you build your parameter value. Heck, even a flat file would work.
-craig

"You can never have too many knives" -- Logan Nine Fingers
devesh_ssingh
Participant
Posts: 148
Joined: Thu Apr 10, 2008 12:47 am

Post by devesh_ssingh »

you meant to increment through counter in sequence
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

I meant what I said - leverage a sequence object, say in a database or job. A Sequence job could control that, sure, and pass it to the job that needs it.
-craig

"You can never have too many knives" -- Logan Nine Fingers
devesh_ssingh
Participant
Posts: 148
Joined: Thu Apr 10, 2008 12:47 am

Post by devesh_ssingh »

@Craig
Let me know if i got it right this time
Generate sequence number through another job and pass the value to *running no * param and eventually to file

@qt_ky

as far i as i know Oconv is used to convert string to a specified format for external output. no clue how it will generate sequence number.
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

Through another job or a custom routine or a script or whatever mechanism you feel comfortable building and supporting. And then the rest, yes. I would leverage a Server job and USER_STATUS for the first part in your shoes.
-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 »

My suggestion was that you could generate whatever values you need to in a User Variables stage of a Sequence job.

The Oconv() function is just one example that you could use. Normally you would use Oconv() along with Date() and possibly Time() in order to generate a custom timestamp format, which you had posted in your first question. I did not suggest it for generating a sequence number.
Choose a job you love, and you will never have to work a day in your life. - Confucius
Post Reply