I agree with others to the extent that I would not want existing code to
work differently than it does now.
However, I think there's more to it.
There are three potential benefits to such a feature:
1. Less coding when a sort is needed.
2. No unexpected and unwelcome runtime errors caused by out-of-sequence
3. Less disk usage when a sort and another step run back to back. The sort
would hand observations directly to the next process.
Daniele speaks of a temporary dataset and so does not anticipate #3, but I
think it would be an important dividend.
Now could Daniele's suggestion be implemented without getting in anybody's
way? How about an AUTOSORT option to invoke the new behavior? It could be in
the PROC step;
proc whatever data=someds autosort;
or in the BY statement
proc whatever data=someds;
by id / autosort;
but I think the added granularity of a dataset option might be best:
proc whatever data=someds(autosort);
As to benefit #3, how about PROC SORT views?
On Wed, 8 May 2002 11:48:34 +0200, Daniele Monzali
>has anyone ever proposed to SAS inst. to avoid explicitely sorting datasets
>in order to perform "by" operations ? (analysis procs, proc transpose, you
>name the others). it could be done with an internal sorting procedure (yes,
>i know, in every proc) outputting the data= sas dataset to a temporary one
>upon which the PROC would perform the usual analysis.
>sorry if i ask what may seem a stupid question, but since V9 seems to be so
>improved and "augmentated" i was wondering if such an improvement had
>already been considered and somehow discarded.