ORACLE modifies the use of ALTER CONSTAINTS in the table structure

  • 2021-12-11 19:23:03
  • OfStack

1. Create a federated primary key

ALTER TABLE table name ADD CONSTRAINTS end name PRIMARY KEY (column name, column name..);

2. Add characters

ALTER TABLE table name ADD (COLUMN DATATYPE [DEFAULT VALUE] [NULL/NOT NULL]);

3. Delete columns

ALTER TABLE table name DROP (COLUMN) J;

4. Modify the characters of the table

ALTER TABLE Table Name MODIFY (COLUMN DATATYPE [DEFAULT VALUE] [NULL/NOT NULL])


Related articles: