BookmarkSubscribeRSS Feed
raghu7
Calcite | Level 5

Hi All,

 

Is there any way to get the "{xxx }"  these in the report including braces, as i have to show this in report using ods rtf.

2 REPLIES 2
RW9
Diamond | Level 26 RW9
Diamond | Level 26

Please follow the guidance on the page when posting a new question, post test data in the form of a datastep and what you want the output to look like, otherwise we are just guessing.

data have;
  a="{xxx }";
run;

ods rtf file="abc.rtf";
proc report data=have nowd;
  columns a;
run;
ods rtf close;
ballardw
Super User

How are you generating your output?

Do you mean that you have numeric values that will appear in a table and that you want to enclose, possibly a range of them, in {}

such as

{123.4}?

 

You may have to provide additional information such as rules, number of decimals to display if any. The most likely approach would be a custom picture format such as shown here:

proc format library=work;
picture braces
low-high = '00009.9}' (prefix='{' );
run;


data have;
  input x;
datalines;
-123
0
234.5
;

proc print data=have;
  var x;
  format x braces.;
run;

SAS Innovate 2025: Call for Content

Are you ready for the spotlight? We're accepting content ideas for SAS Innovate 2025 to be held May 6-9 in Orlando, FL. The call is open until September 16. Read more here about why you should contribute and what is in it for you!

Submit your idea!

How to Concatenate Values

Learn how use the CAT functions in SAS to join values from multiple variables into a single value.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 2 replies
  • 829 views
  • 0 likes
  • 3 in conversation