If individual CELLWIDTH values are given in percentages for columns with procedures TEMPLATE, REPORT, PRINT, or TABULATE, and the total for the table is 100%, the table might wrap on the page or across pages. The CELLWIDTH specification on the columns does not take into account the borders (grid lines), so if the total adds up to 100%, there is slightly more width needed for the entire table, causing it to wrap.
To circumvent the problem, use percentages that add up to 98-99% in order to use the full width of the page, but prevent the table from wrapping. Please see the Full Code tab for an example.
The sample code below first shows CELLWIDTH values which add up to 100% and create a wrapped table. The workaround code shows CELLWIDTH values which add up to 98.5% and create a single table with all five columns across each page.
options papersize=letter orientation=portrait;
/* PROBLEM */
ods rtf file="wrapped.rtf";
ods pdf file="wrapped.pdf" notoc;
title "PROBLEM - CELLWIDTHs add up to 100%";
proc report nowd data=sashelp.class style(column)={cellwidth=20%};
run;
ods _all_ close;
/* SOLUTION */
ods rtf file="not_wrapped.rtf";
ods pdf file="not_wrapped.pdf" notoc;
title "SOLUTION - CELLWIDTHs add up to 98.5%";
proc report nowd data=sashelp.class style(column)={cellwidth=19.7%};
run;
ods _all_ close;
Internal-Only Information (not visible on support.sas.com)