Use this statement to add comments about database objects.


Prerequisites for commenting about an object are as follows: 

Object Type Prerequisites
Schema Owner or role DBA
Table or column Owner or role DBA, ALTER object privilege on the table or ALTER ANY TABLE
Function Owner or role DBA
Script Owner or role DBA
User Role DBA, system privilege ALTER USER or system privilege CREATE USER
Role Role DBA or system privilege CREATE ROLE
Connection Role DBA or system privilege CREATE CONNECTION
Consumer group Role DBA or system privilege MANAGE CONSUMER GROUPS



Comment Table Statement

Comment Table Statement


Comment Object Statement

Usage Notes

  • Using the corresponding metadata system tables (for example, EXA_ALL_OBJECTS, EXA_ALL_TABLES) and the command DESC[RIBE] (with FULL option), comments can be displayed.
  • Comments can be dropped by assigning NULL or the empty string.
  • Comments can also be defined in the CREATE TABLE statement.
  • View comments can only be specified in the CREATE VIEW statement.
  • Comments are limited to a maximum length of 2000 characters.


COMMENT ON SCHEMA s1 IS 'My first schema';
COMMENT ON TABLE t1 IS 'My first table';
COMMENT ON t1 (id IS 'Identity column', zip IS 'Zip code');
COMMENT ON SCRIPT script1 IS 'My first script';