---------- Lock Table ----------

Access to a table can be restricted during a transaction using the  LOCK_TABLE
command.

Syntax

    lock TABLE [in] | exclusive | [mode]
                    | excl      |
                    | share     |

Locking is only in effect for the current transaction and takes effect immedi-
ately following the issuing of the LOCK TABLE command.

A table may be locked in exclusive or share modes.   An  exclusive  mode  lock
gives  exclusive  access  to the table.  No-one else may select from or update
the table and no other locks may be placed on it concurrently.  A  share  mode
lock  guarantees  only that you will be able to select from the table and pre-
cludes updates by others.

Notes

Several share mode locks can be placed on a table at one time.  If  more  than
one share mode lock exists on a given table that table may not be updated.  If
you have placed the only share mode lock on a table you may perform updates on
that  table.   Records so updated will be locked for the duration of the tran-
saction.

The LOCK TABLE command will only have effect if some level of locking has been
set with the LOCK LEVEL command.

For further information, enter:

help lock_level;
