暂无图片
暂无图片
暂无图片
暂无图片
暂无图片

12c表数据shanhui

Oracle工作笔记 2019-06-06
661
  1. 查询表信息

SELECT owner,
table_name,
tablespace_name,
num_rows,
con_id
FROM cdb_tables
WHERE table_name = Upper('&table_name');

  1. 查询container信息

SELECT *
FROM v$containers
WHERE con_id = '&con_id';

SELECT name
FROM v$containers vc,
cdb_tables ct
WHERE table_name = 'tb_name'
AND vc.con_id = ct.con_id;


  1. 进入container

alter session set container=&container_name;

  1. 查询数据

select * from owner.table_name as of timestamp to_timestamp('2019-06-06 17:50:00', 'yyyy-mm-dd hh24:mi:ss');

  1. 创建新表

create table owner.table_name_bak tablespace tbs_name as select * from owner.table_name as of timestamp to_timestamp('2019-06-06 17:50:00', 'yyyy-mm-dd hh24:mi:ss');

本文分享自微信公众号 - Oracle工作笔记,如有侵权,请联系 service001@enmotech.com 删除。
最后修改时间:2020-01-13 22:19:35
文章转载自Oracle工作笔记,如果涉嫌侵权,请发送邮件至:contact@modb.pro进行举报,并提供相关证据,一经查实,墨天轮将立刻删除相关内容。

评论