在oracle中的视图的列中添加注释

Adding comment to a column of a view in oracle

显然可以添加注释来描述视图,但是在 oracle 中是否可以添加注释来描述视图的单个列?

comment on column

Use the COMMENT statement to add a comment about a table, view, materialized view, or column into the data dictionary.

例子

create table tst_delete (col1 int); 

create view v_tst_delete as select * from tst_delete;

检查 SQLPlus

SQL> comment on column v_tst_delete.col1 is 'is my view column comment';

Comment added
SQL> desc v_tst_delete
Name Type    Nullable Default Comments                  
---- ------- -------- ------- ------------------------- 
COL1 INTEGER Y                is my view column comment 

SQL>