Support for variable length character variables.

From sasCommunity

Jump to: navigation, search
sasCommunity Forum : What I would like in SAS : Support for variable length character variables.

By Fruitynewt on Tue Apr 17, 2007 5:55 pm

In my view it would be useful if SAS had support for varchar() type variables. How many people retrieve their data from an RDB where character variables are large? My data source presents character variables as varchar(2000) and I have to query the max(length) using proc sql so that I know how big they really are and avoid wasting space.

Rick.





Last edited by Fruitynewt on Tue Apr 17, 2007 5:55 pm

Private Message | Personal Page | Quote


By Frank.boekamp on Sun Apr 22, 2007 5:55 am

Fruitynewt said:
In my view it would be useful if SAS had support for varchar() type variables. How many people retrieve their data from an RDB where character variables are large? My data source presents character variables as varchar(2000) and I have to query the max(length) using proc sql so that I know how big they really are and avoid wasting space.

Rick.





Hi Rick,

I don't know if you are aware of the SAS system option compress to reduce the size of your data sets?

Still SAS needs to know the length of a variable to create space in the Program Data Vector so you will have to determine the max lenght...

Cheers, Frank


Private Message | Personal Page | Quote


By Peter.Crawford on Fri Aug 17, 2007 6:50 pm

I'll bet you it's coming in SAS9.2 among the datatypes of the new "sas table server". But it won't be part of a SAS9 data set.

Simple (character) compression achieves the easiest compromise. It can be applied as individual data sets are written

  proc sort out= space_saved( compress= yes) ;

or applied globally with

option  compress= yes ;

The compress feature was always neccessary once character variables could be much wider than $200.





Last edited by Peter.Crawford on Fri Aug 17, 2007 6:51 pm

Private Message | Personal Page | Quote


Showing page 1/1


Forum section Powered by MWBB
Views
Personal tools