SQL/MP Report Writer Guide

Using SQLCI and the Report Writer
HP NonStop SQL/MP Report Writer Guide527213-001
2-10
Entering Report Formatting Commands
Entering Report Formatting Commands
The report formatting commands must be associated with a specific SELECT
command. You can enter these commands only at the select-in-progress prompt (S>).
This prompt appears after you enter the SELECT command, but only if the number of
rows to be listed is greater than the current value of the LIST_COUNT session option.
If you want to enter report formatting commands, you should set a low LIST_COUNT
value: for example, 0 or 1.
In Figure 2-8, DETAIL, BREAK ON, and BREAK TITLE are report formatting
commands that refer to the selected data.
Figure 2-8. Example of Report Formatting Commands
>> SET LIST_COUNT 0;
>> VOLUME PERSNL;
>> SELECT * FROM DEPT, EMPLOYEE
+> WHERE DEPT.DEPTNUM = EMPLOYEE.DEPTNUM
+> ORDER BY DEPT.DEPTNUM, EMPNUM;
S> DETAIL DEPT.DEPTNUM, EMPNUM, LAST_NAME;
S> BREAK ON DEPT.DEPTNUM;
S> BREAK TITLE DEPT.DEPTNUM (DEPTNAME);
S> LIST NEXT 8;
DEPTNUM
FINANCE
EMPNUM LAST_NAME
FINANCE
1000
1500
23
202
208
210
214
209
211
212
HOWARD
CLARK
CRAMER
BARTON
KELLY
CHAPMAN
SCHNEIDER
MITCHELL
Break Title
Break Title
S>
VST0208.vsd