ALTER TABLE (Adabas only)

 

Function

Add column to an existing Adabas file.

 

Syntax

 

image23.jpg

 

Table Specification:

See Table Specification.

 

SQL Data Type:

See SQL Data Types under SQL Language Elements.

 

 

column_name

SQL identifier for the new column.

 

Description
ALTER TABLE adds the specified column to the Adabas file.  Any column added by ALTER TABLE is nullable.
 
Limitations

Only the DBA may execute this statement for any user. All other users can only change their user information.

 

CONNX_Groups.bmp

 

Caution: This statement is not subject to transaction logic. An implicit COMMIT will be performed after successful execution of this statement. If an error is detected during execution of this statement, an implicit ROLLBACK will be performed. Before you execute this statement, complete any open transaction containing INSERT, UPDATE and/or DELETE statements by issuing an explicit COMMIT or ROLLBACK statement.

 

ANSI Specifics

The ALTER TABLE statement is not part of the ANSI Standard.

 

Examples

The following example shows a user adding a column called test to an Adabas file called ORDERS.

ALTER TABLE ORDERS ADD COLUMN TEST CHAR(40) NULL;