Commands
COMMENT ON
You can use the COMMENT ON
command to add comments on tables or columns in RisingWave. Comments are stored as metadata of tables or columns.
If you want to remove an existing comment on a table or column, rewrite the current comment with NULL
.
Syntax
Parameters
Parameter | Notes |
---|---|
object_type | Type of the object that you want to add comments to. Allowed values: TABLE, COLUMN. |
relation_name.object_name | Name of the object that you want to add comments to. For columns, you also need to specify the table name. |
comment | Comment that you want to add. |
Examples
Add a comment on a table:
Add a comment to a column:
Remove the comment on a table:
After a comment is added to a table or column, you can display it in these ways:
- Using the
rw_description
table:
- Using the
SHOW COLUMNS
orDESCRIBE
command:
Related topics
Was this page helpful?