Previous Page | Next Page

Dictionary of ODS Language Statements

ODS LISTING Statement



Opens, manages, or closes the LISTING destination.
Valid: anywhere
Category: ODS: SAS Formatted

Syntax
Without an Action or Options
Actions
Options

Syntax

ODS LISTING <action>;
ODS LISTING <DATAPANEL=number | DATA | PAGE > <FILE=file-specification>;


Without an Action or Options

If you use the ODS LISTING statement without an action or options, it opens the LISTING destination.


Actions

An action performs one of the following procedures:

An action is one of the following:
CLOSE

closes the LISTING destination and any files that are associated with it.

Tip: When you close an ODS destination, ODS does not send output to that destination. Closing an unneeded destination frees some system resources.
EXCLUDE exclusion(s)| ALL | NONE

excludes one or more output objects from the LISTING destination.

Default: NONE
Restriction: The LISTING destination must be open for this action to take effect.
Main discussion: ODS EXCLUDE Statement
SELECT selection(s) | ALL | NONE

selects output objects for the LISTING destination.

Default: ALL
Restriction: The LISTING destination must be open for this action to take effect.
Main discussion: ODS SELECT Statement
SHOW

writes the current selection or exclusion list for the LISTING destination to the SAS log.

Restriction: The LISTING destination must be open for this action to take effect.
Tip: If the selection or exclusion list is the default list (SELECT ALL), then SHOW also writes the entire selection or exclusion list.
See also: ODS SHOW Statement

Options

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.

Note:   In this context, a page is what the procedure uses as a page in creating the listing output. The SAS system options LINESIZE= and PAGESIZE= generally determine the page size, although some procedures (PROC REPORT, for example) can temporarily override the values that the system options specify.  [cautionend]

number

writes the specified number of observations in a panel, if possible. More than one panel can occur on every page if space permits.

Range: 1 to the largest integer that the operating system supports
DATA

bases the size of the panel on the way that the table is stored in memory. This value provides the fastest performance. However, if the table contains many columns, the number of rows in each panel might be small.

PAGE

tries to make panels that match the page size. If the table contains more columns than can fit on a page, the first page is filled with as many observations as possible for as many columns as can fit on a single line. The second page contains the same observations for the next group of columns, and so on, until all rows and columns have been printed.

This arrangement minimizes the amount of space that is used for column headings because most pages contain observations for only one set of columns.

Restriction: If the page size is greater than 200, ODS uses DATAPANEL=200.
Default: PAGE
DEVICE= device-driver

specifies the name of a device driver. ODS automatically selects an optimal default device for each open output destination.

The following table lists default devices for the most common ODS output destinations.

Output Destination Default Device
HTML PNG
LISTING Host Specific Display Device (PC- WIN, UNIX - XColor, MVS -Display Device)
Measured RTF PNG
RTF SASEMF
PCL SASPRTM (Monochrome Output)*
PDF SASPRTC (Color Output)*
POSTSCRIPT SASPRTC (Color Output)*
PRINTER Host Specific Default Printer*
* Does not support changing the default device in the SAS Registry.

Tip: Specifying a device on the ODS DEVICE= option takes precedence over the SAS global option and the graphics option.
See: DEVICE= System Option in SAS Language Reference: Dictionary. See Device Drivers in SAS/GRAPH: Reference for information on selecting device drivers.
FILE=file-specification

specifies the file to write to. file-specification is one of the following:

'external-file'

is the name of an external file to which to write.

fileref

is a file reference that has been assigned to an external file. Use the FILENAME statement to assign a fileref. (For information about the FILENAME statement, see SAS Language Reference: Dictionary.)

Default: If you do not specify a file to write to, ODS writes the output to the LISTING window.
GPATH= file-specification <(url='Uniform-Resource-Locator' | NONE)>

specifies the location for all graphics output that is generated while the destination is open.

file-specification

specifies the file or SAS catalog to which to write. ODS names automatically each output object that it places in the file. If you specify an invalid filename, the ActiveX and Java devices send output to the default filename. Other devices create the file as a directory and write output to that directory using the default filename. For more information about how ODS names catalog entries and external files, see SAS/GRAPH: Reference. file-specification is one of the following:

external-file

is the name of an external file to write to.

Requirement: You must enclose external-file in quotation marks.
fileref

is a file reference that has been assigned to an external file. Use the FILENAME statement to assign a fileref. For information about the FILENAME statement, see SAS Language Reference: Dictionary.

Interaction: If you specify a fileref in the GPATH= option, ODS does not use information from the GPATH= option when it constructs links.
libref.catalog

specifies a SAS catalog to which to write.

URL= 'Uniform-Resource-Locator' | NONE

specifies a URL for file-specification.

Uniform-Resource-Locator

is the URL you specify. ODS uses this URL instead of the filename in all the links and references that it creates to the file.

Requirement: You must enclose Uniform-Resource-Locator in quotation marks.
NONE

specifies that no information from the GPATH= option appears in the links or references.

Tip: This option is useful for building output files that can be moved from one location to another. If the links from the contents and page files are constructed with a simple URL (one name), they will resolve if the contents, the page, and body files are all in the same location.
IMAGE_DPI=

specifies the image resolution of ODS graphics output. Output from device-based graphics is not affected.

Default: 100
Restriction: The IMAGE_DPI= option affects template-based graphics only.
PACKAGE <package-name>

specifies that the output from the destination be added to a package.

package-name

specifies the name of a package that was created with the ODS PACKAGE statement. If no name is specified, then the output is added to the unnamed package that was opened last.

See also:

ODS PACKAGE Statement

SGE= ON | OFF

determines whether you can edit ODS graphics output with the ODS Graphics Editor.

Default: OFF
Restriction: The SGE= option affects template-based graphics only.
See also: SAS/GRAPH: ODS Graphics Editor User's Guide

Previous Page | Next Page | Top of Page