Date: Mon, 16 Dec 2002 12:31:21 -0500
Reply-To: "Droogendyk, Harry" <Harry.Droogendyk@CIBC.COM>
Sender: "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From: "Droogendyk, Harry" <Harry.Droogendyk@CIBC.COM>
Subject: Re: Proc cimport and sortinfo
Content-Type: text/plain; charset="iso-8859-1"
Shukla:
Sure works fine when going from Windows to Windows...
Specify the "sortedby" dataset option when doing the cimport. I realize
that's not as seamless as SAS handling it with the sortinfo parm, but it
does set the sortedby value on the destination dataset.
You could roll your own sortinfo mechanism I suppose, extracting the
sortedby info, sending that down the PC, dealing with it first and using it
to set a macro variable that's used as a dataset option on the cimport if
applicable.
-----Original Message-----
From: Roland [mailto:roland@RASHLEIGH-BERRY.FSNET.CO.UK]
Sent: December 16, 2002 12:10 PM
To: SAS-L@LISTSERV.UGA.EDU
Subject: Re: Proc cimport and sortinfo
What you should do is assume the dataset is sorted in the
order you want.
That way you will not have to sort it again.
"Roland" <roland@rashleigh-berry.fsnet.co.uk> wrote in
message
news:atl1ap$ot7$1@news5.svr.pol.co.uk...
> When you create a new dataset from a sorted dataset then
the sort
> information is always lost.
>
> "Shukla Kshirsagar" <shuklak@HOTMAIL.COM> wrote in message
> news:200212161658.gBGGw5D12239@listserv.cc.uga.edu...
> > Hello everybody,
> >
> > I have created a sorted (ascii) transport data set on
the mainframe,
which
> > I download to the PC.
> >
> > proc sort data=sastemp.temp1 ascii;
> > by id;run;
> >
> >
> > When the SAS data set is created on the PC, if I look at
the properties,
> > the 'sorted by' info is blank. If I use proc sort on
this data set, SAS
> > sorts it over again, but not really, since the data set
was already
sorted
> > by ID. I had created a variable called counter=_n_, and
the sorted
> dataset
> > has the same order for counter as the unsorted data set.
> >
> > On the mainframe side, my code looks like this:
> >
> > proc cport data=sastemp.temp1 file=xout sortinfo=yes;
> > run;
> > The log gives
> > Warning:The Sortinfo option is obsolete.
> >
> > I am using SAS version 8.1 on the PC and 8.2 on
mainframe. Given the
size
> > of our data, it would be optimal for us to sort on the
mainframe and
> > download to the PC.
> >
> > Thanks for all your help,
> > Shukla
>
>
|