Usage Note 24228: What are appropriate ESCAPECHAR= values for output tables?
You must choose your escape character wisely. You might already know that your
escape character cannot occur
in the data or in the strings
in the titles, dates, text=, and so forth. You must also be careful not to
clash with the split character.
If you use an escape character at the start of a table header,
you must also specify SPLIT=.
This is because
in column headers, if you haven't defined a split character, then the
first character of the string is examined; if it is a nonname character
(not alphanumeric or underscore), then it is stripped off and used as
the split character.
The split is processed very early, before the escape character.
This is a particular problem when the procedure uses the name or label as the column
header, such as in the DATA step interface. It's also a problem
in the REPORT procedure, where the slash (/) is the default SPLIT=
value.
In the following example, SPLIT= is specified in the header definition:
proc template;
delete FooBar;
define table FooBar;
style=[borderwidth=0 cellpadding=0];
column Column_One;
define column Column_One;
define header x;
style=[background=white font_size=12pt ];
end;
header=x;
split='!'; /* specify split character */
end;
end;
run;
ods listing close;
ods pdf file='C:\temp\ods.pdf';
ods escapechar = '\';
data _null_;
file print ods=(template='FooBar');
length Column_One $100;
/* escape character at start of table header */
label Column_One = "\nColumn_One Header\1.5n" ;
Column_One = 'Line 1';
put _ods_;
run;
ods pdf close;
Usage of ESCAPECHAR= is briefly summarized in a topic about
inline
formatting in the Base Community.
Operating System and Release Information
*
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.
| Type: | Usage Note |
| Priority: | low |
| Topic: | SAS Reference ==> ODS (Output Delivery System) System Administration ==> Printing SAS Reference ==> DATA Step
|
| Date Modified: | 2005-10-11 12:04:57 |
| Date Created: | 2005-02-15 09:53:50 |