README for the HP Neoview Command Interface (NCI) (R2.3)

GOTO Command
All commands executed after a GOTO statement are ignored until the
specified label is set. The GOTO command cannot currently jump back in the
command history; it is a forward-only command. To set a label, use the
LABEL command.
Syntax:
GOTO { Label }
Label is a string of characters without quotes and spaces, or a quoted
string.
This command has to be entered on a single line.
Example:
SQL> GOTO ViewManagers
SQL> SELECT * FROM Employees; -- skipped
SQL> SHOW RECCOUNT; -- skipped
SQL> LABEL ViewManagers
SQL> SELECT * FROM Managers;
SQL> GOTO "View Customers"
SQL> SELECT * FROM Invoices; -- skipped
SQL> LABEL "View Customers"
SQL> SELECT * FROM Customers;
IF...THEN Command
IF...THEN statements allow for conditional execution of actions. If the
condition is met then the action is executed, otherwise no action is
taken.
Syntax:
IF { condition } THEN { action } { SQLTERMINATOR }
The condition parameter is a Boolean statement structured as follows:
condition
{ variable-name | value } { operator } { variable-name | value }
variable-name
{ LASTERROR | RECCOUNT | ACTIVITYCOUNT | ERRORCODE |
[%] any ENV variable | any SQL parameter }
value
{ any-integer | quoted-string }
quoted-string
"any non-quote character" [\] is the optional escape character
operator
The following is a list of valid operators and their meanings
== | = equal to
<> | != | ~= | ^= not equal to