Problem inputting raw data on SAS Server

Reply
Occasional Contributor
Posts: 5

Problem inputting raw data on SAS Server

Hello--

I have a simple input statement that I am using to test a program.  It works fine in SAS 9.3 and EG 5.1 on my personal machine.  However, when I try this on my work computer, which uses EG 6.1 through the SASApp Server, it has issues.  The syntax is fine, so I cannot understand what the issue is.

data example;

  input productgroup $ state $ id amount price;

cards;

lumber  NC 17442 21324 66.83

lumber  NC 17951 353726 19.40

;

run;

Any help would be greatly appreciated, since this seems to be a simple issue and it's driving me crazy.

Nick

ps.  I can "force" it to work with length statements, but I shouldn't have to.  Also, not practical since I will sometimes be testing this with larger datasets.\

Occasional Contributor
Posts: 5

Re: Problem inputting raw data on SAS Server

I can also force it to work by altering the statement to

data example;

  infile cards delimiter=',';

  input productgroup $ state $ id amount price;

cards;

lumber,NC,17442,21324,66.83

lumber,NC,17951,353726,19.40

;

run;

This seems unnecessary, since the original syntax was correct....am I missing something here?  I'm losing my mind....

Super User
Super User
Posts: 6,498

Re: Problem inputting raw data on SAS Server

What is the error message?

Occasional Contributor
Posts: 5

Re: Problem inputting raw data on SAS Server

Weird....

I tried the old "turn it off and turn it back on" trick and now it's working.  Maybe the server had stored a stale image of the data set somehow?  Either way, thanks for response.

Super User
Posts: 9,671

Re: Problem inputting raw data on SAS Server

Maybe your work computer mistake blank delimiter as TAB delimiter , just guess.

data example;

infile cards  expandtabs ;

input productgroup $ state $ id amount price;

cards;

lumber  NC 17442 21324 66.83

lumber  NC 17951 353726 19.40

;

run;

Xia Keshan

Ask a Question
Discussion stats
  • 4 replies
  • 200 views
  • 0 likes
  • 3 in conversation