Help using Base SAS procedures

How can i Convert Numeric data to Char ?

Reply
N/A
Posts: 0

How can i Convert Numeric data to Char ?

How can i Convert Numeric data to Char ? Where can i see all the SAS Column FUnctions
TIA
Super User
Posts: 5,255

Re: How can i Convert Numeric data to Char ?

There are numerous SAS papers/documentation on this subject. The PUT function will do this.

In DI Studio, you will see most SAS functions available in the Expression Builder window, in the Functions tab, where they are categorized. For a full list of SAS functions, see on-line doc.

/Linus
Data never sleeps
Trusted Advisor
Posts: 2,113

Re: How can i Convert Numeric data to Char ?

One of the standard ways to do the convert is with the INPUT function.

NumVar=INPUT(CharVar,Format_for_CharVar);

e.g. if CharDays is a character field that is 4 columns wide,
Days=INPUT(CharDays,4.);

The functions are all described in the SAS documentation, under the Base SAS product:
http://support.sas.com/documentation/

Doc Muhlbaier
Duke
N/A
Posts: 0

Re: How can i Convert Numeric data to Char ?

Thanks.
SB
Ask a Question
Discussion stats
  • 3 replies
  • 120 views
  • 0 likes
  • 3 in conversation