SQL/MX Remote Conversational Interface (RMXCI) Guide for SQL/MX Release 3.1 (H06.23+, J06.12+)

SQL>create trigger handlecheckout
+> after insert on checkout
+> referencing new as newr
+> for each row
+> update member set dues = dues + 10
+> where memberid = newr.memberid;
+> /
For the syntax of the create trigger statement, see the SQL/MX Release 3.x Reference Manual.
Logging output
To log a RMXCI session, use the spool or log command. These commands record into a log file
the commands that you enter in the RMXCI interface and the output of those commands.
“Starting the logging process” (page 45)
“Stopping the logging process” (page 46)
“Viewing the contents of a log file” (page 46)
Starting the logging process
Run one of the following commands:
spool on or log on
spool log-file or log log-file
For more information, see the “LOG command” (page 72) and the “SPOOL command” (page 115).
SPOOL ON or LOG ON command
The spool on or log on command logs information about a session in the sqlspool.lst
file, which RMXCI stores in the installation directory. For example:
rmxci-installation-directory/sqlspool.lst
rmxci-installation-directory is where you have installed the RMXCI software files. For
more information, see Table 2 (page 17).
For example, this spool on command starts logging the session in the sqlspool.lst file:
SQL>spool on
SPOOL log-file or LOG log-file command
The spool log-file and log log-file commands record information about a session in a
log file, which you specify. If you specify a directory for the log file, the directory must exist.
Otherwise, an error is returned when you try to run the spool or log command. If you do not
specify a directory for the log file, the spool is written to the installation directory.
For example, this command starts logging the session in the persnl_updates.log file in the
/home/usr/log directory:
SQL>spool /home/usr/log/persnl_updates.log
Using the CLEAR option
The clear option clears the contents of an existing log file before logging new information in the
file. If you omit clear, RMXCI appends new information to existing information in the log file.
For example, this command clears existing information from the specified log file and starts logging
the session in the log file:
SQL>spool /home/usr/log clear
Logging output 45