Displaying Selected Attributes

Part of designing a report is explicitly specifying the data it will include. For example, the user may want to generate a report from the ORDERS file. The ORDERS dictionary defines twelve different attributes, but only four of them are pertinent to the report. In this case, the user would include the names of those four attributes in the query. This explicit list of attributes is called an output specification.

If such a specification is not included in a query, the system produces a default display. The section titled Using INFO/ACCESS Syntax describes this fully. See Default Processing of INFO/ACCESS Parameters.

The following report example displays items from the CUSTOMERS file. It includes the customers’ last names and first names. The report also includes item-IDs, which are the default output specification for a data file.

The report displays the data in columnar format, which is the default format for INFO/ACCESS reports unless the sum of the column widths exceeds the page width as defined by the TERM command. In this case, the report lists the data vertically, in noncolumnar format.

>LIST CUSTOMERS LAST-NAME FIRST-NAME

 

 

 

PAGE   1        10:54:53  DD MMM YYYY

 

 

 

CUSTOMERS...

Last Name...

First Name

 

 

 

HJENK7129

JENKINS

HAROLD

JBOHA5422

BOHANNON

JOHN

KBROO6749

BROOKS

KATHY

JBUCK6488

BUCKLER

JULIE

BLEAR6803

LEARY

BILL

JMASO6378

MASON

JULIA

AORLA5993

ORLANDO

AMY

SPIRS5289

PIRS

SANDRA

MASHX5777

ASH

MARY

AEDWA5224

EDWARDS

ANTHONY

JPEER5993

PEERCE

JAN

RPIER5539

PIERCE

RICK

AJOHN5396

JOHNSON

ANNE

HJOHN7265

JOHNSON

HENRY

HHIGG6849

HIGGINS

HENRY

DEDGE6635

EDGECOMB

DAVID

BLAMP6196

LAMPSON

BOB

AMEAD5619

MEADE

ANDREW

 

 

 

ITEMS LISTED.

Had the columns been too wide for the screen, items in the preceding report would be displayed as in the next report example.

PAGE   1       10:37:11  DD MMM YYYY

 

CUSTOMERS : HJENK7129

Last Name   JENKINS

First Name  HAROLD

 

CUSTOMERS : JBOHA5422

Last Name   BOHANNON

First Name  JOHN

 

CUSTOMERS : KBROO6749

Last Name   BROOKS

First Name  KATHY

 

CUSTOMERS : JBUCK6488

Last Name   BUCKLER

First Name  JULIE

 

CUSTOMERS : BLEAR6803

Last Name   LEARY

First Name  BILL

Calculate the width of a report using these instructions:

See Also

Producing Reports with LIST and SORT

Using the LIST and SORT Commands

Using Selection Expressions

Using SORT Expressions

Using Print Limiters

Producing Vertical Listings with LIST-ITEM