NonStop SQL/MP Reference Manual

Table Of Contents
NonStop SQL/MP Reference Manual142115
R-20
ConsiderationsRESET REPORT
You can specify the SELECT option only at the standard SQLCI prompt, >>.
Considerations—RESET REPORT
You cannot reset a command that defines an alias or detail alias (such as NAME or
DETAIL) if other current report commands use the alias or detail alias, so the order
in which you reset report commands is significant. For example, if a SUBTOTAL
command refers to a detail alias, you must reset the SUBTOTAL command before
you reset the DETAIL command. (Note that aliases are reset by RESET REPORT
NAME, but detail aliases are reset by RESET REPORT DETAIL.)
Examples—RESET REPORT
The following example uses RESET REPORT at the select-in-progress prompt.
SHOW REPORT commands display the stored report formatting commands before
and after the RESET REPORT. Note that the * option does not affect the SELECT
in effect for the report.
S> SHOW REPORT *;
SELECT * FROM INVENT.ODETAIL ORDER BY PARTNUM;
DETAIL PARTNUM HEADING "Part Number", SPACE 5, QTY_ORDERED;
BREAK ON PARTNUM;
SUBTOTAL QTY_ORDERED;
S> RESET REPORT *;
S> SHOW REPORT *;
SELECT * FROM INVENT.ODETAIL ORDER BY PARTNUM;
The following example uses RESET REPORT at the standard SQLCI prompt.
SHOW REPORT commands display the stored report formatting commands before
and after the RESET REPORT. Note that in this example, unlike the previous one,
the * option deletes both the report formatting options and the SELECT.
>> SHOW REPORT *;
SELECT * FROM INVENT.ODETAIL ORDER BY PARTNUM;
DETAIL PARTNUM HEADING "Part Number", SPACE 5, QTY_ORDERED;
BREAK ON PARTNUM;
SUBTOTAL QTY_ORDERED;
>> RESET REPORT *;
>> SHOW REPORT *;