The SAS Output Delivery System and reporting techniques

data import

Reply
New Contributor jbr
New Contributor
Posts: 4

data import

importing data with the following format:

test>lname>fname>l>someid>newid>testcode>3>>311>345>EN\
U>Sun Certified System Administrator for Sun Cluster 3.2>SE345>\
A>100>0>0>1>DTW>04/26/2007>10:28:27>02:11:27>ny130>1>191 fitzpa\
trick trail>address>st>14586>USA>1>5853346029>>NONE GIVE\
N>0>>>>>>>>2>emp_no=eds3009>se_email=carin.maxson@eds.com>0>75>>\
129/42/0/t>0>200>2>NDA>seNDA>n>p>0>0>>0/0/0/t>Sun Certified Sys\
tem Administrator for Sun Cluster 3.2>mainA>s>p>0>75>>129/42/0/\
t>0>176>NDA2002.1a>2>0>>2>s>A>0>9>>NDA2002.2a>2>0>>3>s>B>0>36>>\
.....more data

note how some data is moved to following line. the "/" is a line continuation character in the data. how to address that is my issue
PROC Star
Posts: 1,759

Re: data import

Do you mean "\" is a line continuation character ?

The data is difficult to decipher.

What would the records look like if they were stored one per line?
PROC Star
Posts: 1,759

Re: data import

One entry per question please.
Super Contributor
Super Contributor
Posts: 3,174

Re: data import

I am not sure you need to be concerned about a line-continuation character, which I believe is a back-slash, not a forward-slash. And, from your data, the column-delimiter might be ">" - correct?

With this in mind, the SAS INPUT process can read from multiple lines based on INFILE statement parameters. However, you will need to address the back-slash character during INPUT -- it likely has no real purpose with SAS performing INPUT statement.

My recommendation is you start by coding up a DATA step to read your input file with an INPUT statement and the desired INFORMATs, depending on your data.


Scott Barry
SBBWorks, Inc.
New Contributor jbr
New Contributor
Posts: 4

Re: data import

yes the 'backslash' is the line continuation character and the delimiter is '>'
Valued Guide
Posts: 2,177

Re: data import

that is a very inconvenient structure for SAS input routines.
It looks like a stream. Line breaks occur within words.
Is there an expected order for this information ?
Is there some equivalent to a "row delimiter" ?
Ask a Question
Discussion stats
  • 5 replies
  • 168 views
  • 0 likes
  • 4 in conversation