DATA Step, Macro, Functions and more

double trailing option

Accepted Solution Solved
Reply
Super Contributor
Posts: 336
Accepted Solution

double trailing option

I tried to use sas to read a large raw dataset. It can read the first 100+ variables but the rest values are all missing.

INPUT  
@8 id $1.	 @@;
run;

SAS ran very slowly without error message. Any advice?

 


Accepted Solutions
Solution
‎06-30-2016 03:50 PM
Contributor
Posts: 63

Re: double trailing option

why you are using double trail option to read it...

@@ is used to divide varible name in to two observation.....any specific requirement for using double trail?

View solution in original post


All Replies
Super User
Posts: 5,085

Re: double trailing option

Advice:  don't retest this under any circumstances.

 

It's likely that someone canceled the job.  This is an infinite loop, that continuously reads the contents of column 8 from the first line of raw data. 

 

Perhaps there are later statements that might cause the program to eventually finish on its own.  More likely, it began taking up so much disk space that an administrator took action.

Contributor
Posts: 63

Re: double trailing option

I am not understadning your question completly, but I am guessing , your record length is less.

 

So just try to increase the length of input data file.

 

syntax:

 

LINESIZE=n | MIN | MAX | hexX

 

give maximum length of record.

 

LS= 1024(I am assuming max number).

 

try this or let us know complete issue.

 

Super Contributor
Posts: 336

Re: double trailing option

LINESIZE=256

 

LS= 1024

I do not know I understand it correctly, when i add @@ and put these two you mentioned, it still ran so slowly and had to terminate each time

 

Solution
‎06-30-2016 03:50 PM
Contributor
Posts: 63

Re: double trailing option

why you are using double trail option to read it...

@@ is used to divide varible name in to two observation.....any specific requirement for using double trail?

Super Contributor
Posts: 336

Re: double trailing option

Thanks. no i only want sas not stop readding

 

 I only want SAS to read all those  correctly. Now it can only read the first 100+ variables, leaving the rest 50 variables missing values/blank

I have set linesize=32767

still same

Super User
Posts: 17,868

Re: double trailing option

Can you post a sample of your data? Is it possible you have a line feed character that would cause reading a line to be truncated?

Super Contributor
Posts: 336

Re: double trailing option

Would you please let me know the line feed chacters.

I tried to create a sample dataset, it wonot work

 

currently the code can read the first 180 variables, only 20 var values are missing. Because many obs lack of values for many variables,   it is hard to tell exactly which variable it stops at

I find it canot read a certain date

 

it might be the format of date, any advice for that

or maybe because of space for next page?

Super User
Posts: 5,085

Re: double trailing option

It would also help to see the full INPUT statement.  The one you posted doesn't match the results you are describing.

☑ This topic is SOLVED.

Need further help from the community? Please ask a new question.

Discussion stats
  • 8 replies
  • 442 views
  • 0 likes
  • 4 in conversation