Desktop productivity for business analysts and programmers

Change values in a column

Reply
New Contributor
Posts: 2

Change values in a column

Hi,

I am trying to change the value in a column using EG. I want to change the full name of the product to an abbreviated name. Is there a function that will allow me to do this?

Thanks!
Contributor
Posts: 30

Re: Change values in a column

Have you tried the Recode option in the Computed Columns or create a format
SAS Employee
Posts: 149

Re: Change values in a column

Recode or user-defined format that Derek mentioned are probably the best solutions for what you want.

If you want to abbreviate by literally take the first X characters from each product name, you can use a SUBSTR function to do that. Create a computed column based on an expression, and for the expression use something like

SUBSTR(column1,1,8)

===starts at the first character of column1 and extracts exactly 8 characters===
New Contributor
Posts: 2

Re: Change values in a column

Thanks, I tired the recode a column, and it did exactly what I needed!
Ask a Question
Discussion stats
  • 3 replies
  • 192 views
  • 0 likes
  • 3 in conversation