Date: Mon, 14 Jul 2008 14:58:13 -0400
Reply-To: Randy Herbison <RandyHerbison@WESTAT.COM>
Sender: "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From: Randy Herbison <RandyHerbison@WESTAT.COM>
Subject: Re: SAS/AF: Copy and Paste into Table Viewer from Excel
In-Reply-To: <7367b4e20807141134l30ffe264p4222fe8435598a44@mail.gmail.com>
Content-Type: text/plain; charset="us-ascii"
Both the data step and SCL eliminate the need to mess around with column
numbers. Multiple data set columns needlessly complicate the SAS/AF
task. The data step doesn't use MISSOVER, because it is inconsistent
with the double trailing at-sign (@@).
The SCL advantage is that it doesn't require writing and reading a disk
file while performing a GUI operation.
-----Original Message-----
From: data _null_, [mailto:datanull@gmail.com]
Sent: Monday, July 14, 2008 2:35 PM
To: Randy Herbison
Cc: SAS-L@listserv.uga.edu
Subject: Re: SAS/AF: Copy and Paste into Table Viewer from Excel
I ran this...
data __pb(keep=row value);
length value $ 200 row 8 lastline 8;
retain lastline;
infile ft44f001 dsd dlm="09"x lrecl=32767 line=line;
input value @@;
if line > lastline then row + 1;
lastline=line;
run;
So how is that better or different from using MISSOVER.
On 7/14/08, Randy Herbison <RandyHerbison@westat.com> wrote:
> Did you try the code?
>
> Neither the data step nor the SCL ignore or remove blanks lines. If
> present, they are processed like any other line and are available for
> pasting into the table viewer.
>
>
>
> -----Original Message-----
> From: SAS(r) Discussion [mailto:SAS-L@LISTSERV.UGA.EDU] On Behalf Of
> data _null_,
> Sent: Monday, July 14, 2008 2:08 PM
> To: SAS-L@LISTSERV.UGA.EDU
> Subject: Re: SAS/AF: Copy and Paste into Table Viewer from Excel
>
>
> On 7/14/08, Randy Herbison <RandyHerbison@westat.com> wrote:
> > It depends on how you read the data. This data step handles
> > completely blank lines, but doesn't need MISSOVER:
>
> I figured someone would say that. I don't see why anyone would not
> use MISSOVER unless you want to remove the completely blank lines.
> Now, that does seem reasonable to me.
>
> Here is another way using LENGTH= infile option that seems simpler to
> me.
>
> data excel;
> infile ft44f001 dlm='09'x dsd length=l;
> array c[*] ⦥
> input @;
> if l=0 then return;
> input @1 c[*];
> list;
> run;
>
>
|