Specific patterns file name and path change

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
Amin
Premium Member
Premium Member
Posts: 27
Joined: Fri Oct 24, 2014 10:02 am

Specific patterns file name and path change

Post by Amin »

How to move to another folder and rename specific pattern files using shell script in Datastage like file_name_currentDate()_123.txt to file_name to file_name_olddate.txt ?
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

The same way you'd do it without DataStage. Do you need help with the 'in DataStage' part or the actual scripting?
-craig

"You can never have too many knives" -- Logan Nine Fingers
Amin
Premium Member
Premium Member
Posts: 27
Joined: Fri Oct 24, 2014 10:02 am

Post by Amin »

Yes we want Script but the new filename will be generated from DataStage using user variable stage of Sequence job and pass variable to script.
qt_ky
Premium Member
Premium Member
Posts: 2895
Joined: Wed Aug 03, 2011 6:16 am
Location: USA

Post by qt_ky »

There is more than one way to do it. What have you tried so far, and which part do you need some help with? Please be specific.
Choose a job you love, and you will never have to work a day in your life. - Confucius
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

Have DataStage generate the file name and pass it to a script as a command line argument.
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