Hi VA experts,
Is there a way to insert a line break using concatenate operator in SAS VA? For example, I have a table that looks like this:
Issue Action1 Action2 Action3
I want to concatenate those last 3 columns into one column called 'Action'. The Action column should look like below:
Action1
Action2
Action3
Thanks for any help you can provide!
Hello,
All calculations in the VA expression editor are evaluated at the row level (one row in, one row out) so it should not be possible to output multiple rows in the way you want.
I believe one approach to what you want to do would be to use the TRANSPOSE procedure in your data preparation stage. You can get help with that in the SAS Procedures community
Let us know if that helps,
Sam
If I understand correctly, the request is that the three values are in one table cell, but they will display with linebreaks when you add them to a List Table object? I think this is not possible, sorry.
Edit: Actually, it is not that simple. You can use the "\n" escape sequence to specify a newline character, but it appears that this is ignored most of the time. It does appear to be honored in data tips. This is not recommended, I am seeing some buggy behavior with this.
I am investigating this with the dev team.
Here is something you can do:
In text: Concatenate(Concatenate('Text'n, ' - '), 'Text'n)
So the idea is to use the concatenate function multiple times.
Join us for SAS Innovate 2025, our biggest and most exciting global event of the year, in Orlando, FL, from May 6-9. Sign up by March 14 for just $795.
See how to use one filter for multiple data sources by mapping your data from SAS’ Alexandria McCall.
Find more tutorials on the SAS Users YouTube channel.