BookmarkSubscribeRSS Feed
HimaAalamuri
Fluorite | Level 6

Hi Good Morning,

i am trying to convert RTF file to SAS Dataset but i dn't get solution and i go through with some articles also but no use please get me out from this problem.

Study:XXXX                                                                                                                                                Date: todaydate

Listing 10-3

Demographics

_________________________________________________________________________________

                                             Subject/Age/Sex                             Treatment start

                                                                                                          Date

_____________________________________________________________________________________________                            

                                            0001-001/45/M                             19Jan2013

                                            0001-002/55/M                             29Jan2013

                                            0001-003/43/M                             12Jan2013

                                            0001-004/42/M                             15Jan2013

                                            0001-005/55/M                             29Jan2013

                                            0001-006/35/M                             16Jan2013

_____________________________________________________________________________________________________________________________________

Note: All patients are shown.

Thanks in advance!!

Thanks in advance!!

Hima

2 REPLIES 2
Kurt_Bremser
Super User

- save as plain text file

- inspect with a good text editor

- determine how to identify the lines that contain data

- write a data step that reads the text file, discards unwanted lines, and converts the input either with a proper input statement or by manually splitting the _infile_ variable.

LinusH
Tourmaline | Level 20

If this is one time job: copy/paste to flat file format. Edit so it will be in strict columnar format. Going via Excel might help doing the formatting.

If this is a repetitive task: contact the creator of the document and require a different file format.

Data never sleeps

sas-innovate-2024.png

Join us for SAS Innovate April 16-19 at the Aria in Las Vegas. Bring the team and save big with our group pricing for a limited time only.

Pre-conference courses and tutorials are filling up fast and are always a sellout. Register today to reserve your seat.

 

Register now!

How to Concatenate Values

Learn how use the CAT functions in SAS to join values from multiple variables into a single value.

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
  • 2 replies
  • 1025 views
  • 2 likes
  • 3 in conversation