BookmarkSubscribeRSS Feed
Visser
Calcite | Level 5

I want to combine the text of several columns into 1 computed column using SAS Query builder. I can't seem to figure it out 😞

3 REPLIES 3
againreddy
Obsidian | Level 7
on Query builder -> Click on "Computed column" -> Click on "New" -> Select "Advanced Expression" -> Type trim(column1)||trim(column2)||trim( column3)
-> click on "next" -> Enter new column name and click on "Finish"

Notes:
1. Column1 to 3 are your columns in your table
2.You can use trim/compress functions based on your choice.
Visser
Calcite | Level 5

Thx! It worked!

TomKari
Onyx | Level 15

There are also a number of cat... functions that are great for this kind of thing; cat, catq, cats,catt, catx.

sas-innovate-2026-white.png



April 27 – 30 | Gaylord Texan | Grapevine, Texas

Registration is open

Walk in ready to learn. Walk out ready to deliver. This is the data and AI conference you can't afford to miss.
Register now and lock in 2025 pricing—just $495!

Register now

Creating Custom Steps in SAS Studio

Check out this tutorial series to learn how to build your own steps in SAS Studio.

Find more tutorials on the SAS Users YouTube channel.

SAS Training: Just a Click Away

 Ready to level-up your skills? Choose your own adventure.

Browse our catalog!

Discussion stats
  • 3 replies
  • 3690 views
  • 0 likes
  • 3 in conversation