BookmarkSubscribeRSS Feed
angird1990
Calcite | Level 5

angird1990_0-1704262942341.png

Hi All,

I tried to use this piece of code with datapanel option in ods statement. But I'm not getting 5 columns in the output. The output displays all the collumns and 29 rows per page. Am I not using it in the right way? Please suggest.

 

2 REPLIES 2
ballardw
Super User

From online documentation of the Datapanel option for listing (with emphasis added):

DATAPANEL=number | DATA | PAGE

suggests how to split a table that is too wide to fit on a single page into sections of columns and rows. Each section of columns and rows is a data panel. Each data panel has column headings at the top.

The datapanel only kicks in when the default page size will not fit the current width.

number

writes the specified number of observations in a panel, if possible

The number is rows displayed in a panel, not number of columns. The number of columns will depend on the values and the LINESIZE option setting for LISTING.

 

 

 

 

 

angird1990
Calcite | Level 5

Thanks for your suggestion. I tried this dataset which had around 7000 variables but still the output is not 5 rows per panel. Could you please try this?

 

ods listing datapanel=5;
data aa;
set sashelp.leutest(obs=10);
run;
proc print;
run;
ods listing close;

hackathon24-white-horiz.png

2025 SAS Hackathon: There is still time!

Good news: We've extended SAS Hackathon registration until Sept. 12, so you still have time to be part of our biggest event yet – our five-year anniversary!

Register Now

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
  • 2 replies
  • 855 views
  • 0 likes
  • 2 in conversation