Previous Topic: Notes on Performing Cross-system SQL OperationsNext Topic: Tools for Importing, Exporting, and Backing up Tables


List of SQL Statements

The SQL statement has a maximum length of 2048 characters. The following table describes the SQL statements the CA OPS/MVS product supports.

Note: For syntax information, see the chapter “Relational Data Framework Reference” in the Command and Function Reference.

ALTER TABLE

Adds columns to a table.

Type of operation: Table

Invoke from a TSO terminal: Yes

Invoke from a TSO/E REXX, TSO CLIST, or OPS/REXX program or from an AOF Rule: Yes

CLOSE

Ends a cursor operation

Type of operation: Cursor

Invoke from a TSO terminal: No

Invoke from a TSO/E REXX, TSO CLIST, or OPS/REXX program or from an AOF Rule: Yes

CREATE TABLE

Defines a new relational table to CA OPS/MVS.

Type of operation: Table

Invoke from a TSO terminal: Yes

Invoke from a TSO/E REXX, TSO CLIST, or OPS/REXX program or from an AOF Rule: Yes

DECLARE CURSOR

Defines a cursor operation.

Type of operation: Cursor

Invoke from a TSO terminal: No

Invoke from a TSO/E REXX, TSO CLIST, or OPS/REXX program or from an AOF Rule: Yes

DELETE FROM

Deletes the current row (in a cursor operation) or rows that meet your selection criteria (in a searched operation).

Type of operation: All

Invoke from a TSO terminal: Yes

Invoke from a TSO/E REXX, TSO CLIST, or OPS/REXX program or from an AOF Rule: Yes

DROP TABLE

Deletes a table.

Type of operation: Table

Invoke from a TSO terminal: Yes

Invoke from a TSO/E REXX, TSO CLIST, or OPS/REXX program or from an AOF Rule: Yes

FETCH

Retrieves all of the column values for the current row.

Type of operation: Cursor

Invoke from a TSO terminal: No

Invoke from a TSO/E REXX, TSO CLIST, or OPS/REXX program or from an AOF Rule: Yes

INSERT

Inserts a row into a table.

Type of operation: Table

Invoke from a TSO terminal: Yes

Invoke from a TSO/E REXX, TSO CLIST, or OPS/REXX program or from an AOF Rule: Yes

OPEN

Initiates a cursor operation and executes a SELECT statement.

Type of operation: Cursor

Invoke from a TSO terminal: No

Invoke from a TSO/E REXX, TSO CLIST, or OPS/REXX program or from an AOF Rule: Yes

SELECT

Retrieves column values in rows that meet your search criteria.

Type of operation: Searched

Invoke from a TSO terminal: Yes

Invoke from a TSO/E REXX, TSO CLIST, or OPS/REXX program or from an AOF Rule: Yes

UPDATE

Updates column values for the current row (in a cursor operation) or rows that meet your selection criteria (in a searched operation).

Type of operation: All

Invoke from a TSO terminal: Yes

Invoke from a TSO/E REXX, TSO CLIST, or OPS/REXX program or from an AOF Rule: Yes