我们在创建表的时候一般都会给表以及表中的列添加注释,方便了解表以及字段的意思:
1.给表填加注释:comment on table 表名 is '表注释";
2.给列加注释:comment on column 表.列 is '列注释';
3.读取表注释 select * from user_tab_comments where comments is not null and table_name='表名';
4.读取列注释:select * from user_col_commnents where comments is not null and table_name='表名';