BookmarkSubscribeRSS Feed
deleted_user
Not applicable
Why does this compute after not work. All I get is the word 'TOTAL'.

COMPUTE BEFORE GROUP_TYPE;
HOLD_GROUP = GROUP_TYPE;
ENDCOMP;

BREAK AFTER GROUP_TYPE /SUMMARIZE SKIP DOL DUL;

COMPUTE AFTER GROUP_TYPE;
ACCT= 'TOTAL'||TRIM(HOLD_GROUP);
ENDCOMP;
1 REPLY 1
Cynthia_sas
Diamond | Level 26
Hi:
Just a guess. ACCT has a length of $5 or $6??? When you use this technique to put special text at the break, you are limited to the length of the variable on the left-hand side of the = sign.

You may find the answer in this Advanced Proc Report Topics paper:
http://support.sas.com/rnd/papers/sgf07/sgf2007-report.pdf

...or one of the techniques is shown here:
http://support.sas.com/faq/043/FAQ04326.html

There are several other methods for addressing this length limitation with PROC REPORT (user-defined format, changing the length of the original variable). If you have an immediate need, you could contact Tech Support for help with any of these techniques.

cynthia

hackathon24-white-horiz.png

The 2025 SAS Hackathon has begun!

It's finally time to hack! Remember to visit the SAS Hacker's Hub regularly for news and updates.

Latest Updates

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.

SAS Training: Just a Click Away

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

Browse our catalog!

Discussion stats
  • 1 reply
  • 1004 views
  • 0 likes
  • 2 in conversation