【SQL】表/列增加注释

发布时间 2023-07-19 10:34:49作者: Phoenixy

表增加注释

comment on table 表名 is '表注释";

 

 

列增加注释

comment on column 表.列 is '列注释';

 

 

读取表注释

select * from user_tab_comments where comments is not NULL AND TABLE_NAME = '表名';

 

 

读取列注释 <可能不存在表 user_col_commnents >

select * from user_col_commnents where comments is not null and table_name='表名';