isql Commands
Go Up to Command-line isql Tool
Contents
At the SQL> prompt, you can enter any of three kinds of commands:
- SQL data definition (DDL) statements, such as
CREATE,ALTER,DROP,GRANT, andREVOKE. These statements create, modify, or remove metadata and objects, and control user access (via privileges) to the database. For more information about DDL, see the Data Definition Guide. - SQL data manipulation (DML) statements such as
SELECT,INSERT,UPDATE, andDELETE. These four data manipulation operations affect the data in a database. They retrieve, modify, add, or delete data. For more information about DML statements, see the Language Reference. isqlcommands that fall into three main categories:
SHOWcommands (to display metadata or other database information)SETcommands (to modify theisqlenvironment)- Other commands (for example, commands to read an input file, write to an output file, or end an
isqlsession)
Some isql commands have many options. See isql Command Reference
SHOW Commands
SHOW commands are used to display metadata, including tables, indexes, procedures, and triggers.
SHOW commands list all of the specified objects or give information about a particular object when used with <name.>
SHOW commands operate on a separate transaction from user statements. They run as READ COMMITTED background statements and acknowledge all metadata changes immediately.
SET Commands
SET commands enable you to view and change the isql environment.
Other isql Commands
The remaining isql commands perform a variety of useful tasks, including reading a SQL file, executing shell commands, and exiting isql. The other isql commands are: BLOBDUMP, EDIT, EXIT, HELP, INPUT, OUTPUT, QUIT, SHELL.
QUIT and EXIT Commands
To exit the isql utility and roll back all uncommitted work, enter:
SQL> QUIT;
To exit the isql utility and commit all work, enter:
SQL> EXIT;