Date: Fri, 21 Mar 1997 18:24:41 -0500
Reply-To: flickner@erols.com
Sender: "SAS(r) Discussion" <SAS-L@UGA.CC.UGA.EDU>
From: Pat Flickner <flickner@EROLS.COM>
Organization: Flickner Enterprises
Subject: Re: Change the position of the variable in SAS data set
Content-Type: text/plain; charset=us-ascii
Philip Primak wrote:
>
> Is there a way to change the position of the variable in SAS data set.
> I have SAS data set and PROC CONTENTS gives me the output like this:
>
> # Variable Type
> --------------------------
> 1 PATID num
> 2 AGE num
> 3 SEX char
> .
> .
> .
>
> I need to make SEX 2 and AGE 3.
>
> Thanks in advance for any help.
>
> Philip Primak
Philip,
Why? If it's because of proc print, you can alway use VAR to reorder
the variables. Otherwise, you can read the SAS set into another SAS set
and do (keep=patid sex age). Otherwise, is it really worth the extra
trouble?
Pat Flickner
flickner@erols.com
|