Date: Tue, 6 Dec 2005 23:18:39 -0500
Reply-To: "Howard Schreier <hs AT dc-sug DOT org>" <nospam@HOWLES.COM>
Sender: "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From: "Howard Schreier <hs AT dc-sug DOT org>" <nospam@HOWLES.COM>
Subject: Re: Reading the data from the excel file into SAS by row by row
and cell by cell
In addition to the good points raised by Toby and David ... I see no
connection between the code shown and the stated subject (Excel, rows,
columns).
On Tue, 6 Dec 2005 08:28:41 -0800, syam <syam1919@GMAIL.COM> wrote:
>Hi All,
>
>I have written this code but I am facing little problems with this can
>anybody suggest upon this;
>
>
>%LET CSYAM_LIBLOC = 'C:\data\syam\';
>%LET CDRIVE_LIBLOC = 'C:\data\mail id data\';
>
>LIBNAME CSYAM &CSYAM_LIBLOC;
>LIBNAME CDRIVE &CDRIVE_LIBLOC;
>
>%MACRO NUM_OBSER(START= ,END= );
>
> DATA _NULL_;
> SET CSYAM.file_data;
> DO IND = &START TO
&END;
> IF Unique_Index =
IND THEN
>
PLAN_CODE_TEMP = TRIM(Plan_Code);
>
MEDIA_CODE_TEMP = TRIM(Media_Code);
> %PUT
&START;
> %PUT &END;
>
PUT PLAN_CODE_TEMP;
> INDI =
&IND;
> END;
> RUN;
>
>%MEND NUM_OBSER;
>
>%NUM_OBSER(START=1, END= 2);
>
>
>The log for abov is as:
>
>1
>2
>NOTE: Line generated by the invoked macro "NUM_OBSER".
>4 PUT PLAN_CODE_TEMP;
>4 ! INDI = &IND; END;
> RUN;
> -
> 22
>WARNING: Apparent symbolic reference IND not resolved.
>
>ERROR 22-322: Syntax error, expecting one of the following: a name, a
>quoted string,
> a numeric constant, a datetime constant, a missing value,
>INPUT, PUT.
>
>Can anybody help me out from this.
>
>Thanks.
>
>Regards,
>Syam
|