Date: Wed, 13 Aug 2003 14:03:58 -0700
Reply-To: Prasad S Ravi <prasad.s.ravi@HOUSEHOLD.COM>
Sender: "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From: Prasad S Ravi <prasad.s.ravi@HOUSEHOLD.COM>
Subject: Re: importing flat files of unknown variables
Content-type: text/plain; charset=us-ascii
Do you have the layout of this file stored some where, by layout I mean,
type, length and name of the variables
in a separate file which you can use it as a input statement to read in the
fields.
Or else you can use a DO loop to read all the variables with a common name
prefix something like X1 through X100;
Or if you have SAS/ACCESS you can use PROC IMPORT to read the data.
Prasad Ravi
The Fords
<gford95@COMCAST.NET> To: SAS-L@LISTSERV.UGA.EDU
Sent by: "SAS(r) cc:
Discussion" Subject: importing flat files of unknown variables
<SAS-L@LISTSERV.UGA.E
DU>
08/13/2003 11:47 AM
Please respond to The
Fords
This maybe a common question, but is there any way in base sas to import a
flat file without specifying the variable names? For instance, if I have a
.csv file with 100 variables, is there a way to get that data set into sas
without explicitly naming the variable (and not using the import wizard or
copy and paste, etc.)?
Thanks,
Greg
|