BookmarkSubscribeRSS Feed
DPraba79
Calcite | Level 5
Hi,

Sas provides layout from cobol to sas convertion (COB2SAS tool). However, i have a situation like, i have sas file layout, i would like to convert this sas layout to COBOL readable lay out. Does sas offer any tool to accomplish this task?

Thanks!
1 REPLY 1
Cynthia_sas
SAS Super FREQ
Hi:
I'm a little confused about your question. COB2SAS converts from a COBOL data description section into a SAS INPUT statement. Generally, you are doing this because you have a sequential or "flat file" that you were reading with COBOL and you want to transform that file into a SAS dataset by reading it with SAS.

Once you run the SAS program with the INPUT statement, the data (in SAS) are no longer in the sequential or flat layout described by the INPUT statement, they are stored in a SAS proprietary format.

So, when you say that you have a SAS layout -- do you mean you have an INPUT statement? And you want to convert that INPUT statement to a COBOL data description?

Or do you mean that you want to get a SAS proprietary format data file into some other form on some other platform?

In any case, there is no "SAS2COB" routine to translate a SAS INPUT statement into COBOL form. But, if you do have a flat file that needs to be read with COBOL, a good COBOL book should help you with this task. If you need to get a SAS data file into some other form, you can create a flt file using FILE/PUT statement in a DATA step program. You can use any of the SAS/Access products to write SAS data into some other form (or read some other form of data into SAS form).

For more help accessing data or writing data out, you can also contact SAS Tech Support.

cynthia

sas-innovate-2024.png

Don't miss out on SAS Innovate - Register now for the FREE Livestream!

Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.

 

Register now!

SAS Enterprise Guide vs. SAS Studio

What’s the difference between SAS Enterprise Guide and SAS Studio? How are they similar? Just ask SAS’ Danny Modlin.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 1 reply
  • 1687 views
  • 0 likes
  • 2 in conversation