`

表和字段的注释

 
阅读更多
1、给表加注释
COMMENT ON TABLE land.landsellmend IS '补办出让';

2、查看表的COMMENT
SELECT * FROM USER_TAB_COMMENTS WHERE TABLE_NAME='LANDSELLMEND';

3、给字段加注释
comment on column document.doc.bid is '批号';

4、查看字段的COMMENT:
SELECT * FROM USER_COL_COMMENTS WHERE TABLE_NAME='LANDSELLMEND';

5、查看字段的详细信息
   select t.column_name,t.data_type,t.data_length,t.DATA_PRECISION ,t.DATA_SCALE, u.comments,T.OWNER
from all_tab_columns t inner join user_col_comments u on t.COLUMN_NAME=u.column_name where u.table_name='APPSYS_MKSYB' and t.TABLE_NAME=u.table_name and t.OWNER='用户名'

6. 查询表

select * from tabs.

7.查询表的所有字段

select * from user_tab_cols where table_name ='C_RESOURCE_TABLE'

分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics