ISQL Statements

End of Orders Summary Report

23 records selected ISQL>

3.5THE HELP AND TABLE STATEMENTS

ISQL supports an on-line help facility that can be invoked by using the HELP statement. Typing HELP at the ISQL prompt will display a help file which will list the options accepted by the HELP statement. The various forms of the HELP statement are listed below:

HELP - Displays the options that can be specified for HELP.

HELP COMMANDS - Displays all the statements that ISQL accepts.

HELP command_name - Displays help file corresponding to the specified statement.

TABLE is an ISQL statement that displays all the tables present in the database including any system tables. TABLE can be used also to display the description of a single table by explicitly giving the table name. Both forms of the TABLE statement are shown below:

TABLE;

TABLE table_name;

3.6TRANSACTION SUPPORT

A transaction is started with the execution of the first SQL statement. A transaction is committed using the COMMIT WORK statement and rolled back using the ROLLBACK WORK statement.

If the AUTOCOMMIT option is set to ON, then ISQL treats each SQL statement as a single transaction. This prevents the user from holding locks on the database for an extended period of time. This is very critical when the user is querying an on-line database in which a transaction processing application is executing in real time.

A set of SQL statements can be executed as part of a transaction and committed using the COMMIT WORK statement. This is shown below:

<SQL statement>

<SQL statement>

<SQL statement>

COMMIT WORK ;

Instead, a transaction can also be rolled back using the ROLLBACK WORK statement as shown:

<SQL statement>

<SQL statement>

FairCom Corporation

3-11