BookmarkSubscribeRSS Feed
Quartz | Level 8


I am trying to get repeated values to be shown one of my group columns in proc report. I have tried the trick described in the Allison McMahill's article:


IF week NE ' ' then holdw=week;

IF week EQ ' ' then week=holdw;


However this trick does not work when spanrows option is enabled (and I need it to be enabled for the other columns to avoid confusion). Is there a way to get this thing working? Any help is much appreciated.



  You can't turn SPANROWS on and off for different variables. Once SPANROWS is turned on, it is on for ALL the ORDER or GROUP items you have. Since you didn't post data or your complete code or desired results or name your destination of interest, it's hard to make any other comments.


Quartz | Level 8

I did not mean to switch the SPANROWS on and off, either completely off or on. However the problem is that the trick I mentioned in the original post does not worki if SPANROWS is on. I have edited my first post and attached a sample data and code for my issue, there I only get the "stairstep" report table no matter what I do. And in fact with the data I generated the spanrows does really odd things and somehow makes some across values disappear. The problem is I can't post the actual data here, and it is really hard to mimic it. But basically with that data I would want to get all the order/group variables to show in every row and then get the table in "normal" form not in this stairstep formation which is really frustrating (somehow with the actual data I have managed to get the table to transpose it naturally, but couldn't get it working with the sample data...)


Available on demand!

Missed SAS Innovate Las Vegas? Watch all the action for free! View the keynotes, general sessions and 22 breakouts on demand.


Register now!

What is Bayesian Analysis?

Learn the difference between classical and Bayesian statistical approaches and see a few PROC examples to perform Bayesian analysis in this video.

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
  • 2 in conversation