BookmarkSubscribeRSS Feed
sasiscool
Obsidian | Level 7

Is there any way with a compute statement or using the _RBREAK_ column to add a break line in a proc report anywhere i would like.

 

for instance, breaks are linked to the grouping variable, and one could place one after or before the defined grouping variable in a report.

 

e.g.


proc report data=work.final
column question online_type_desc, (n response1);
define question/group f=$question. 'Question';
define online_type_desc/across f=$online.;
define n/ f=comma8.;

define response1/analysis mean f=8.2 'Average' ;

 

break after question/summarize.....

 

However, lets say I don't want to break after the natural breaks in question. I want to break every 3rd line? I assume i could make a dummy grouping variable and hide it, but this might change too.  In this report, every 3 lines, but in the next, I want to break it every 5th line. Is there anyway to do this within the proc report code itself?

2 REPLIES 2
arodriguez
Lapis Lazuli | Level 10

Hello,

 

If in your reports you want to break every 3 lines or X lines, you could edit the page size with 

 

options ps=3;

This will make that the natural break page change to the 3th line.

 

Also you could create a group variable as you have said and create a compute after like this

 break after GROUPING_VAR  / page;

This will create the break "_PAGE_" character at the end of each group.

 

I hope that this help you

 

 

 

sasiscool
Obsidian | Level 7

hey thanks man for the the tips. I wasn't aware of the page function.

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

Discussion stats
  • 2 replies
  • 2060 views
  • 0 likes
  • 2 in conversation