Page 1 of 1

How to access an INI file and its value

Posted: Wed Dec 18, 2002 10:24 pm
by sankar18
Hi All,

Requirement is like this:

Mail ids will be in INI file.

How to access the INI file and its value from DataStage.
the value has to send to DSSendmail as an input value.

Thanks in Advance,
T Sankar

Posted: Wed Dec 18, 2002 11:32 pm
by ray.wurlod
In a Routine (or in a job control routine):
open the INI file with OpenSeq
read it a line at a time with ReadSeq
when done, close it with CloseSeq

A useful construct is the Boolean context of ReadSeq, which you can use to exit your loop reading the file. For example:
Loop
While ReadSeq Line From filevariable
* process the line, e.g. build list of addresses
* for sendmail
Repeat