oracle 12c 新特性三:rman命令窗口可以执行sql语句

教程发布:风哥 教程分类:ITPUX技术网 更新日期:2022-02-12 浏览学习:1165

oracle 12c 新特性三:rman命令窗口可以执行sql语句

在oracle 12c之前的版本中,rman命令窗口中是不可以直接执行sql查询语句。而在oracle 12c中 rman中是可以直接运行sql语句,

对于数据库管理员来说,确实方便很多。

以下是具体测试过程 :

[oracle@db12c ~]$ rman target /
Recovery Manager: Release 12.1.0.1.0 - Production on Mon Dec 9 21:08:24 2013
Copyright (c) 1982, 2013, Oracle and/or its affiliates. All rights reserved.
connected to target database: ORCL (DBID=1352607797)
RMAN>
RMAN> select machine from v$session;
MACHINE
----------------------------------------------------------------
db12c.oracle.com
db12c.oracle.com
db12c.oracle.com
db12c.oracle.com
db12c.oracle.com
db12c.oracle.com
db12c.oracle.com
db12c.oracle.com
db12c.oracle.com
db12c.oracle.com
db12c.oracle.com
db12c.oracle.com
db12c.oracle.com
db12c.oracle.com
db12c.oracle.com
db12c.oracle.com
db12c.oracle.com
db12c.oracle.com
db12c.oracle.com
db12c.oracle.com
db12c.oracle.com
db12c.oracle.com
db12c.oracle.com
db12c.oracle.com
db12c.oracle.com
db12c.oracle.com
db12c.oracle.com
db12c.oracle.com
db12c.oracle.com
29 rows selected
RMAN>

而在oracle 11gR2 版本中,则是不可以的

C:\Users\Administrator>rman target /
恢复管理器: Release 11.2.0.1.0 - Production on 星期一 12月 9 21:10:00 2013
Copyright (c) 1982, 2009, Oracle and/or its affiliates. All rights reserved.
连接到目标数据库: ORCL (DBID=1360030053)
RMAN> select machine from v$session;
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-00558: 分析输入命令时出错
RMAN-01009: 语法错误: 找到 "identifier": 应为: "advise, allocate, alter, backup,
@, catalog, change, configure, connect, convert, copy, create, crosscheck, dele
te, drop, duplicate, exit, flashback, grant, host, import, list, mount, open, pr
int, quit, recover, register, release, repair, replace, report, reset, restore,
resync, revoke, run, send, set, show, shutdown, spool, sql, startup, switch, tra
nsport, unregister, upgrade, validate, {, " 中的一个
RMAN-01008: 错误标识符: select
RMAN-01007: 在第 1 行第 1 列, 文件: standard input
RMAN

本文标签:
网站声明:本文由风哥整理发布,转载请保留此段声明,本站所有内容将不对其使用后果做任何承诺,请读者谨慎使用!
【上一篇】
【下一篇】