Neoview Script Guide (R2.2)
Examples
• This command changes the Neoview Script session to CS mode operation:
SQL>mode cs
CS#
For more information, see Appendix C (page 141).
• This command returns the Neoview Script session to SQL mode operation:
CS#mode sql
SQL>
OBEY Command
The OBEY command executes the SQL statements and Neoview Script interface commands
contained in a specified script file.
Syntax
OBEY script-file [ (section-name) ]
script-file
is the name of an ASCII text file that contains SQL statements, Neoview Script interface
commands, and comments. If the script file exists outside the local directory where you
launch Neoview Script (by default, the Neoview Script bin directory), specify the full directory
path of the script file.
(section-name)
is the name of a section within the script-file to execute. If you specify section-name,
the OBEY command executes the commands between the header line for the specified section
and the header line for the next section (or the end of the script file). If you omit
section-name, the OBEY command executes the entire script file. For more information,
see “Section Headers” (page 71).
Considerations
• In the Neoview Script interface, you must enter the command on one line. The command
does not require an SQL terminator.
• Put a space between OBEY and the first character of the file name.
• You can execute this command in a script file.
• You can specify only one script file at a time using the OBEY command. To run multiple
script files in parallel, see “Running Scripts in Parallel” (page 73).
Examples
• This OBEY command runs the script file from the local directory (the same directory where
you are running Neoview Script):
SQL>obey ddl.sql
• This OBEY command runs the script file in the specified directory on Windows.
SQL>obey c:\my_files\ddl.sql
• This OBEY command runs the script file in the specified directory on a Linux or UNIX
workstation:
SQL>obey ./my_files/ddl.sql
• This sample file contains sections to be used in conjunction with the OBEY command:
98 Neoview Script Interface Commands