SQL/MP Report Writer Guide
Table Of Contents
- What’s New in This Manual
- About This Manual
- 1 Introduction to the NonStop SQL/MP Report Writer
- 2 Using SQLCI and the Report Writer
- 3 Selecting Data for a Report
- 4 Customizing a Report
- Defining the Layout
- Specifying the Items in a Detail Line
- Naming Select List and Detail Line Items
- Organizing Rows Into Break Groups
- Labeling Information
- Formatting Data Values
- Formatting Dates and Times
- Using TACL to Pass Parameters
- Conditional Printing of Items or Line Entries
- Redefining Special Characters
- Calculating Totals
- Calculating Subtotals
- Printing Double-Byte Characters
- A Comparison of the Report Writer and the Enform Language
- Index

Customizing a Report
HP NonStop SQL/MP Report Writer Guide—527213-001
4-26
Labeling Information
The default display format for the LINE_NUMBER value is I11. To number all detail
lines in one sequence, include the print item:
LINE_NUMBER OVER REPORT
or
LINE_NUMBER
Suppose you want to number the entries in a listing of parts and the suppliers who
supply them. The numbering sequence is to be restarted at each new page. The
following commands produce the list:
>> SELECT * FROM INVENT.SUPPLIER, INVENT.PARTSUPP
+> WHERE SUPPLIER.SUPPNUM = PARTSUPP.SUPPNUM
+> ORDER BY PARTNUM, SUPPLIER.SUPPNUM ;
S> SET STYLE HEADINGS OFF;
S> DETAIL LINE_NUMBER OVER PAGE AS I4,
+> TAB 7,
+> "Part Cost",
+> PARTCOST ,
+> SKIP 1,
+> TAB 7,
+> "Supplier",
+> SUPPLIER.SUPPNUM,
+> SUPPNAME;
S> BREAK ON PARTNUM;
S> BREAK TITLE PARTNUM ("Part ", PARTNUM);
S> TITLE "Parts Supplier List", TAB 48,
+> "Page ", PAGE_NUMBER AS I3;
S> LIST NEXT 5;
Figure 4-13 shows the report.