Writing to a file from a routine

Post questions here relative to DataStage Server Edition for such areas as Server job design, DS Basic, Routines, Job Sequences, etc.

Moderators: chulett, rschirm, roy

Post Reply
Emilio
Participant
Posts: 17
Joined: Wed Jan 28, 2004 2:18 pm
Location: Frederick, MD

Writing to a file from a routine

Post by Emilio »

Hello!
I am fa :) irly new to Ascential DataStage and I have some questions to some of you that are more experienced:

From a routine I need to write into a file.
For example if a code "60Delnq" in a field named "DELINQ60" has not match in Hashfile1, and "code "ALT" in a field "FORCL" has no match in Hashfile2, and so on. I need to write the header name and the code separated by commas into a sequential file like this:
DELINQ60, FORCL, ETC
60Delnq, ALT, ETC

By looking into some examples in the Ascential book, I think I can write the first code, but how do I add the second code separated by a comma or the next row. :?:

Thank You!! :?
kcbland
Participant
Posts: 5208
Joined: Wed Jan 15, 2003 8:56 am
Location: Lutz, FL
Contact:

Post by kcbland »

Use the graphical metaphor and create a link out of a transformer stage. Use your functions or whatever to constrain the output.

Your initial idea is not a good choice, avoid independent file i/o from functions in a transformer stage. Let the tool do the work it was designed to do. You'll be happier with the result in the long run.
Kenneth Bland

Rank: Sempai
Belt: First degree black
Fight name: Captain Hook
Signature knockout: right upper cut followed by left hook
Signature submission: Crucifix combined with leg triangle
Post Reply