LISTSERV at the University of Georgia
Menubar Imagemap
Home Browse Manage Request Manuals Register
Previous (more recent) messageNext (less recent) messagePrevious (more recent) in topicNext (less recent) in topicPrevious (more recent) by same authorNext (less recent) by same authorPrevious page (May 2001, week 1)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:   Thu, 3 May 2001 11:57:46 EDT
Reply-To:   nnair@acf.dhhs.gov
Sender:   "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From:   Neal K Nair <nnair@ACF.DHHS.GOV>
Subject:   Re: Obsolete SAS statements and options
Comments:   To: whitloi1@WESTAT.COM
Comments:   cc: Ian Whitlock <whitloi1@WESTAT.COM>

Ian:

I ran the same program you noted below with the following modification. I used input char x ; cards; abc 1; run; Following that I put: Proc contents data=w position; run; The result is shown below: Alphabetic list of variables and attributes: # variable type len pos 1 char num 8 0 2 x num 8 8

variables ordered by position .... 1 char num 8 0 2 x num 8 8

Note that what I got is different from yours. I wonder why!

Neal

---------- Original Text ----------

From: "Ian Whitlock" <whitloi1@WESTAT.COM>, on 5/3/01 11:50 AM: To: SMTP@Public.11@ACF.WDC[<SAS-L@LISTSERV.UGA.EDU>],Neal K Nair@OPRE@ACF.WDC Cc: SMTP@Public.11@ACF.WDC["Ian Whitlock" <whitloi1@WESTAT.COM>]

Neal,

Yes, you can use the option, POSITION, in version 8, and you may get position order, but then again you may not. (I used to think SAS promised which one.) Try

data w ; retain char "abc" x 1 ; run ;

proc contents data = w position ; run ;

It produces

-----Variables Ordered by Position-----

# Variable Type Len Pos ----------------------------------- 1 char Char 3 8 2 x Num 8 0

Note that CHAR is listed first, but its position comes after that for X.

In prior versions one often used POSITION to obtain the logical order of variables. The options still does this, but it no longer orders by physical position. That is why it was replaced by the VARNUM option and hence became obsolete or deprecated.

However, VARNUM also says

-----Variables Ordered by Position-----

but it omits the position numbers and thus should be considered a mistake in the supporting words of the report instead wrong, since the variables are listed in varnum order and the documentation claims they will be.

Ian Whitlock <whitloi1@westat.com>

On Wed, 2 May 2001 13:04:34 EDT, Neal K Nair <nnair@ACF.DHHS.GOV> wrote:

>Ian: > >I ran a PROC CONTENTS in Version 8 of SAS with the following statement: > >proc contents data=mydatasetname POSITION; run; > >The result I got were: 1) Alphabetic list of variables and attributes > 2) Variables ordered by position >(with all the attributes) >From the result I got, I assumed that the option POSITION is still in >effect. But the version 8 manual does not inlcude that option. Am I wrong?

<snip>


Back to: Top of message | Previous page | Main SAS-L page