Problem Note 41138: FOOTNOTE statement containing multiple JUSTIFY= (or J=) options causes an extra BY line to be placed in output created by ODS PRINTER (PCL/PDF/PS)
If the BYLINE system option is in effect and a FOOTNOTE statement is defined that contains multiple JUSTIFY= (or J=) options to control the justification of text, the output for one or more BY groups might contain an extra BY line in the output created by ODS PRINTER (PCL/PDF/PS).
There are two possible circumventions for this problem:
- Use #BYVAL in conjunction with the NOBYLINE system option.
- Create a macro variable that contains blank spaces to mimic the behavior of the JUSTIFY=R option in the FOOTNOTE. This might require some trial and error as the length of the blank will differ depending on the FOOTNOTE text and the orientation of the ODS PRINTER file.
The Full Code tab contains sample code illustrating the problem and both of the suggested circumventions.
Operating System and Release Information
| SAS System | Base SAS | z/OS | 9.1 TS1M3 SP4 | |
| Microsoft® Windows® for 64-Bit Itanium-based Systems | 9.1 TS1M3 SP4 | |
| Microsoft Windows Server 2003 Datacenter 64-bit Edition | 9.1 TS1M3 SP4 | |
| Microsoft Windows Server 2003 Enterprise 64-bit Edition | 9.1 TS1M3 SP4 | |
| Microsoft Windows XP 64-bit Edition | 9.1 TS1M3 SP4 | |
| Microsoft Windows 2000 Advanced Server | 9.1 TS1M3 SP4 | |
| Microsoft Windows 2000 Datacenter Server | 9.1 TS1M3 SP4 | |
| Microsoft Windows 2000 Server | 9.1 TS1M3 SP4 | |
| Microsoft Windows 2000 Professional | 9.1 TS1M3 SP4 | |
| Microsoft Windows NT Workstation | 9.1 TS1M3 SP4 | |
| Microsoft Windows Server 2003 Datacenter Edition | 9.1 TS1M3 SP4 | |
| Microsoft Windows Server 2003 Enterprise Edition | 9.1 TS1M3 SP4 | |
| Microsoft Windows Server 2003 Standard Edition | 9.1 TS1M3 SP4 | |
| Microsoft Windows XP Professional | 9.1 TS1M3 SP4 | |
| Windows Vista | 9.1 TS1M3 SP4 | |
| Windows Vista for x64 | 9.1 TS1M3 SP4 | |
| 64-bit Enabled AIX | 9.1 TS1M3 SP4 | |
| 64-bit Enabled HP-UX | 9.1 TS1M3 SP4 | |
| 64-bit Enabled Solaris | 9.1 TS1M3 SP4 | |
| HP-UX IPF | 9.1 TS1M3 SP4 | |
| Linux | 9.1 TS1M3 SP4 | |
| Linux on Itanium | 9.1 TS1M3 SP4 | |
| OpenVMS Alpha | 9.1 TS1M3 SP4 | |
| Solaris for x64 | 9.1 TS1M3 SP4 | |
| Tru64 UNIX | 9.1 TS1M3 SP4 | |
*
For software releases that are not yet generally available, the Fixed
Release is the software release in which the problem is planned to be
fixed.
The sample code below illustrates the problem and both of the suggested circumventions.
The problem code creates a 14-page PDF file. The seventh page contains an extra BY line above the TITLE1 text.
There are two workarounds: use #BYVAL in conjunction with the NOBYLINE system option; or create a macro variable that contains blank spaces to mimic the behavior of the JUSTIFY=R option in the FOOTNOTE statement.
/* The following code replicates the problem. */
options nofmterr orientation=landscape papersize=letter nodate nonumber byline;
title1 "TITLE 1";
ods listing close;
footnote1 J=L "LEFT" J=R "RIGHT";
ods pdf file = "&sysvlong.extrabyline.pdf" notoc;
proc sort data=sashelp.cars out=sorted;
by origin make;
run;
proc report data=sorted headline split='|' list nowd;
where origin="Europe";
by origin make;
run;
ods pdf close;
/* The following code illustrates the first workaround: */
/* Use #BYVAL in conjunction with the NOBYLINE system option. */
options nofmterr orientation=landscape papersize=letter nodate nonumber nobyline;
title1 "TITLE 1";
title3 "Origin=#byval(origin) Make=#byval(make)";
ods listing close;
footnote1 J=L "LEFT" J=R "RIGHT";
ods pdf file = "&sysvlong.NOextrabyline.pdf" notoc;
proc sort data=sashelp.cars out=sorted;
by origin make;
run;
proc report data=sorted headline split='|' list nowd;
where origin="Europe";
by origin make;
run;
ods pdf close;
/* The following code illustrates the second workaround: */
/* Create a macro variable that contains blank spaces to */
/* mimic the behavior of the J=R option in the FOOTNOTE. */
%let spacer=%qsysfunc(repeat(%str( ),199));
%put *&spacer*;
options nofmterr orientation=landscape papersize=letter nodate nonumber byline;
ods listing close;
ods escapechar="^";
ods pdf file = "&sysvlong.NOextrabyline2.pdf" notoc;
proc sort data=sashelp.cars out=sorted;
by origin make;
run;
proc report data=sorted headline split='|' list nowd;
where origin="Europe";
by origin make;
title1 "TITLE 1";
footnote j=l "^S={asis=on}LEFT &spacer RIGHT";
run;
ods pdf close;
A FOOTNOTE statement containing multiple JUSTIFY= (or J=) options causes an extra BY line to be placed in output created by ODS PRINTER (PCL/PDF/PS).
| Type: | Problem Note |
| Priority: | medium |
| Date Modified: | 2010-10-25 13:10:12 |
| Date Created: | 2010-10-05 10:58:08 |