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

Using SQLCI and the Report Writer
HP NonStop SQL/MP Report Writer Guide—527213-001
2-15
Defining Reports in Command Files
The semicolon terminator is optional for FC and ! commands. You can enter these
commands at the S> prompt also. If you are listing rows retrieved by a SELECT
command and decide to change the command, use a CANCEL command to return to
the SQLCI prompt. Then enter the FC or ! command.
Defining Reports in Command Files
There are three ways to define a report in a command file:
•
You can prepare the report in steps. This method lets you view the result of the
report formatting commands you enter as you work and then save the report
commands in a file when you are satisfied with the report format.
•
You can create the report commands in a command file using a text editor.
•
You can log only the commands to a log file and then use the log file as a
command file.
Figure 2-9. Example of Repeating Stored Commands
>> SELECT PARTNUM, QTY_AVAILABLE
.. I, PRICE
Example 1
S>
Press RETURN.
..
Insert change and press RETURN.
>> FC SELECT P
>> SELECT PARTNUM, QTY_AVAILABLE, PRICE
Press RETURN.
+> FROM SALES.PARTS;
..
Request History.
SQLCI
displays most
recent
commands.
Reexecute command 3
SQLCI displays and
executes command
Example 2
>> HISTORY 7
3 > SELECT PARTNUM, QTY_ AVAILABLE FROM SALES.PARTS;
4 > LIST ALL;
5 > FC SELECT
P
6 > SELECT PARTNUM, QTY_ AVAILABLE, PRICE FROM SALES.PARTS;
7 > LIST NEXT 3 ;
8 > CANCEL;
9 > HISTORY 7;
>> ! 3
>> SELECT PARTNUM, QTY_ AVAILABLE
+> FROM SALES.PARTS;
VST0209.vsd