Stores a comment about a database object in the system tables.
COMMENT ON { COLUMN [ owner.]table-name.column-name | DBSPACE dbspace-name | EVENT event-name | EXTERNAL ENVIRONMENT environment-name | EXTERNAL OBJECT object-name | FOREIGN KEY [owner.]table-name.role-name | INDEX [ [owner.]table.]index-name | INTEGRATED LOGIN integrated-login-id | JAVA CLASS java-class-name | JAVA JAR java-jar-name | KERBEROS LOGIN “client-Kerberos-principal” | LOGIN POLICY policy-name | MATERIALIZED VIEW [owner.]materialized-view-name | PROCEDURE [owner.]table-name | SERVICE web-service-name | TABLE [ owner.]table-name | TRIGGER [[ owner.]table-name.]trigger-name | USER userid | VIEW [ owner.]view-name } IS comment
COMMENT ON TABLE Employees IS "Employee information"
COMMENT ON TABLE Employees IS NULL
The COMMENT statement allows you to set a comment for an object in the database. The COMMENT statement updates remarks in the ISYSREMARK system table. You can remove a comment by setting it to NULL. The owner of a comment on an index or trigger is the owner of the table on which the index or trigger is defined.
The COMMENT ON DBSPACE, COMMENT ON JAVA JAR, and COMMENT ON JAVA CLASS statements allow you to set the Remarks column in the SYS.ISYSREMARK system table. Remove a comment by setting it to NULL.
You cannot add comments for local temporary tables.
SQL—Vendor extension to ISO/ANSI SQL grammar.
Sybase—Not supported by Adaptive Server Enterprise.
Must either be the owner of the database object being commented, or have DBA authority. (You must have DBA or SPACE ADMIN authority to issue this statement with the DBSPACE clause.)