SQL/MP Reference Manual
HP NonStop SQL/MP Reference Manual—523352-013
S-4
Example—SAVE
-number
is a negative integer that indicates the position of a command in the history buffer 
relative to the current command.
For more information, see HISTORY Command on page H-5.
TO file
specifies a disk file, process file, or terminal name. If the file does not exist, SQLCI 
creates an EDIT file.
section-name
is the simple name of a section header of the form ?SECTION section-name. 
SQLCI writes the section header in the line preceding the attribute values you are 
saving.
CLEAR
directs SQLCI to clear the disk or the process file before saving the commands. If 
you omit this parameter, SQLCI appends the commands to existing text.
You cannot clear individual sections; SQLCI clears the whole file.
The SAVE command is useful for creating an OBEY command file that contains 
DEFINEs you use repeatedly or a report definition you have created using the 
report options and commands.
Example—SAVE
Suppose that you enter these commands during your SQLCI session:
>> VOLUME \SYS1.$VOL1.INVENT;
>> LOG SUBV2.MAYLOG;
>> SYSTEM \SYS1;
>> ADD DEFINE =EMPLOYEE, CLASS MAP,
+> FILE \SYS1.$VOL1.PERSNL.EMPLOYEE;
>> ADD DEFINE =ORDERS, CLASS MAP,
+> FILE \SYS1.$VOL1.SALES.ORDERS;
>> ADD DEFINE =CAT, CLASS CATALOG,
+> SUBVOL \SYS1.$VOL1.PERSNL;
You want to set up this session environment and add these DEFINEs each time 
you execute a particular query. To save the commands, enter:
>> SAVE ENV TO SETUP1 CLEAR;
>> SAVE DEFINES TO SETUP1;
The first command saves the VOLUME, LOG, and SYSTEM commands in the file 
SETUP1. The next command appends all the ADD DEFINE commands to 
SETUP1. To set up the environment and DEFINEs, enter:
>> OBEY SETUP1;










