How to connect and read a SAS dataset in Datastage

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
sarathchandrakt
Participant
Posts: 50
Joined: Fri Aug 29, 2014 1:32 pm

How to connect and read a SAS dataset in Datastage

Post by sarathchandrakt »

Hi,

So far we were downloading SAS datasets manually and using them as input in Datastage jobs. Going forward we have to connect to SAS server and pull data from Datasets directly. There is very limited information available on this online. Can you of you provide your thoughts on this?

I have my server name (let's say ABCD01), port (1234), User ID and Password. I see all the Libraries which have the Datasets. So considering I have Server Name, Port, User ID, Passsword, Library(Lets say 'Maps') and Dataset Names(Lets say 'Country'), how do I call this dataset in Datastage?

Thanks in advance. Any help is appreciated.
anamika
Participant
Posts: 16
Joined: Sat Feb 27, 2016 9:43 am

Post by anamika »

Hi,
For DS to connect to SAS server, DS needs a "plugin" that acts as SAS client. Which does not exist, if I am not mistaken.
However, if you have the SAS client software installed on the same host as the DS server, you can initiate a scripted telnet connection by editing the telnet ".scr" file.
If you have the SAS client installed, you should be able to find the telnet scr file. You can edit it to specify the username and password, the SAS commands to invoke after a successful login. The SAS commands will open the SAS dataset and print/output to console/ODS. This output can then be consumed by any DS stage.
You may want to write a wrapper stage to encapsulate this functionality.
You may need to SAS encode the password as well.

/A
ETL, DW, BI Consultant
Post Reply