Page 1 of 1

Reading SAS code through datastage

Posted: Mon Dec 03, 2018 6:45 am
by rumu
Hi All,

As I am having issues reading binary file with multiple ODO using CFF stage, I am thinking to leverage SAS code that reads the Binary file currently. The SAS code was to be replaced by DataStage, hence the work was started.

As the SAS code is already available, can we use that SAS code through DataStage? I found a SAS stage, but that is for processing SAS datasets. Can I use SAS interface library to use to achieve this? If so can you please help me in steps?

Posted: Mon Dec 03, 2018 9:00 pm
by asorrell
So, just to insure I understand... You have been tasked to replace a SAS process that reads a COBOL binary file with a DataStage process? If so, feeding DataStage from a SAS application won't accomplish your goal - which was to stop using SAS...

Regardless, you can't insert SAS code into a DataStage application. You can integrate C++ or Java, but that can be fairly difficult.

-IF- (note the big "if") the SAS process can somehow be executed on the Linux command line and output its results to stdout, then you can use an External Source Stage. It can take anything from stdout and bring it into DataStage.

Posted: Tue Dec 04, 2018 1:10 am
by ray.wurlod
You should be able to use the Java stage to read the SAS data through the SAS interface library calls.

Posted: Tue Dec 04, 2018 8:56 am
by rumu
Hi Ray,

Can you kindly elaborate on this? How can I call a SAS program that reads a binary file through java stage ? Do I need any SAS license for this ? I was going through the documentation of SAS Interface library call.

Posted: Tue Dec 04, 2018 9:33 am
by chulett
How are your Java coding skills? Or is there someone there you could press into service for this? You would need to write whatever it would be asked to run. Documentation on the stage is here btw.

Posted: Tue Dec 04, 2018 12:46 pm
by rumu
I have 0 knowledge in java ..No one else in the project is there to help ..So not considering this option. Waiting for IBM to respond on multiple ODO clause.