Date: Tue, 2 Mar 2010 03:50:05 -0800
Reply-To: Emil <remilah@GMAIL.COM>
Sender: "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From: Emil <remilah@GMAIL.COM>
Organization: http://groups.google.com
Subject: Re: CONVERTING a ".sas" file into ".dat" file
Content-Type: text/plain; charset=ISO-8859-2
On 2 Mar, 09:58, mark <mark.chas...@yahoo.in> wrote:
> hello ,
>
> i use the codes first to import from excel and second to convert
> from .xls to .sas format .But I need to have the data in .dat
> format.Kindly guide :-
>
> (1)
> PROC IMPORT OUT= WORK.MARCH
> DATAFILE= "c:\Sas\MARCH.xls"
> DBMS=EXCEL REPLACE;
> SHEET="march$";
> GETNAMES=YES;
> MIXED=NO;
> SCANTEXT=YES;
> USEDATE=YES;
> SCANTIME=YES;
> RUN;
>
> (2)
> * convert the excel file into a SAS data file and put it into a
> directory "c:\Sas"*
> libname dis "c:\Sas";
> proc import datafile="C:\Cwa\laptop_review.xls" out=dis.sales replace;
> run
> ;
>
> regards ,
> markc
Hi
try this
data _null_;
set dis.sales;
file ' c:\Sas\dis.dat' ;
put _all_;
run;
Emil Jesiołkiewicz
|