oracle 数据倒库 字段注释维护
2011-02-24 10:37
441 查看
在PLSQL中执行以下语句
连接数据库,执行
【维护字段注释】
select 'comment on column '||table_name||'.'||column_name||' is '''||comments||''';' from user_col_comments
【维护表注释】
select 'comment on table '||table_name||' is '''||comments||''';' from user_tab_comments where comments is not null
点EXPORT QUERYRESULT,把导出的结果,使用TSV方式保存。保存文件后缀改为TXT。如:c:/comment.txt (注分别导出)
打开另外一个数据库 登录sqlpluss
执行@ c:/comment.txt,即可把注释成功写入另一个库中。
连接数据库,执行
【维护字段注释】
select 'comment on column '||table_name||'.'||column_name||' is '''||comments||''';' from user_col_comments
【维护表注释】
select 'comment on table '||table_name||' is '''||comments||''';' from user_tab_comments where comments is not null
点EXPORT QUERYRESULT,把导出的结果,使用TSV方式保存。保存文件后缀改为TXT。如:c:/comment.txt (注分别导出)
打开另外一个数据库 登录sqlpluss
执行@ c:/comment.txt,即可把注释成功写入另一个库中。
相关文章推荐
- Oracle数据字典 和 查询表中字段的注释方法
- 查询Oracle的数据字段与注释
- oracle获取表或视图的字段名、数据类型、注释
- --查询Oracle表字段名称,类型,数据长度,注释的语句
- Oracle修改带数据的字段类型
- Oracle中将一个表中某一字段的数据更新到另一个表中某一字段
- PDO取Oracle lob大字段,当数据量太大无法取出的问题的解决办法
- 导出oracle表、字段注释
- oracle查看该用户的所有表名字、表注释、字段名、字段注释、是否为空、字段类型
- oracle查询表中字段里数据是否有重复
- 在ORACLE中给已有数据的表增加、修改、删除一个字段(或一个列)或者多个字段(或多个列)的问题
- Oracle 增加、修改、删除字段与添加注释
- oracle获取表的字段名称、字段类型、长度、注释、主键的sql语句
- ORACLE 数据库表字段查询报错之ORA-00904:invalid identifier
- 如何实现oracle字段中字符+数字的数据------兼顾字符和数字组合排序
- 使用SQL语句查询MySQL,SQLServer,Oracle所有数据库名和表名,字段名
- 导出oracle数据表及字段方法
- ORACLE 查询所有表,某个表的字段和所有表的字段和注释
- Oracle 数据库换数据库字段的数据类型
- Oracle 数据字典(可用它动态获取字段名、长度、类型等)