The SAS Output Delivery System and reporting techniques

proc report rbreak after label

Reply
Regular Contributor
Posts: 199

proc report rbreak after label

The last row gives the sum of each numeric column.
In the cell that occupies the first column and last row I would like to see the word "Total"
How do I accomplish this?
Thank you.

proc report data=test nowd out=test
style(header)=[font_weight=bold];
options missing='0';
column bu ydoi, (yr_tot);
define bu /group style(column)={just=l};
define ydoi /across '';
define yr_tot /analysis '' format=comma9.;
rbreak after / ol skip summarize;
run;
SAS Super FREQ
Posts: 8,864

Re: proc report rbreak after label

Hi:
You would have a compute block, something like:
[pre]
compute after;
bu='Total';
endcomp;
[/pre]

The only complication is that the internal length of the BU variable must be big enough to hold the string "Total'. There are ways around it if BU is numeric or a length of 2 -- but the simple compute block above should work if the BU variable is character length of at least 5.

cynthia

ps...also, please do me a favor and move your OPTIONS statement outside of your PROC REPORT step. It just bothers me to see the OPTIONS statement in the wrong place.
Ask a Question
Discussion stats
  • 1 reply
  • 537 views
  • 0 likes
  • 2 in conversation