Date: Tue, 5 Aug 2008 18:41:15 -0700
Reply-To: Jack Hamilton <jfh@STANFORDALUMNI.ORG>
Sender: "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From: Jack Hamilton <jfh@STANFORDALUMNI.ORG>
Subject: Re: dropping one variable from a huge dataset without recreating
Content-Type: text/plain; charset=US-ASCII; format=flowed; delsp=yes
On Aug 5, 2008, at 6:15 pm, Lou wrote:
>> The first sentence of the doc page for ALTER says "Adds columns to,
>> columns from, and changes column attributes in an existing table."
>> (http://tinyurl.com/56qm6p or
> Well, I guess you could construe that sentence to mean it drops
> columns from
> a table "in place", that is without rewriting the entire dataset.
> you could make the same statement about the following DATA step (as
> far as
> dropping a column is concerned at any rate)"
> DATA FEE (DROP = FIE);
> SET FEE;
> Neither the DATA step nor PROC SQL appear to get rid of a column
> rewriting the table/dataset. If you make your test table/dataset
> enough that the process takes a minute or three, you can open a
> Explorer window on the library containing the file and by clicking on
> View>Refresh a few times, watch it happening.
On the other hand, if the data set is always rewritten, why this note?
Note: You cannot change the length of a numeric column with the
ALTER TABLE statement. Use the DATA step instead.
What reason could there be for allowing me to change the length of a
character variable, but not of a numeric variable.