描述:
在执行awr报告收集时候报错
SQL> @?/rdbms/admin/awrrpti.sql
Specify the Report Type
~~~~~~~~~~~~~~~~~~~~~~~
Would you like an HTML report, or a plain text report?
Enter 'html' for an HTML report, or 'text' for plain text
Defaults to 'html'
Enter value for report_type:
Type Specified: html
Instances in this Workload Repository schema
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
DB Id Inst Num DB Name Instance Host
------------ -------- ------------ ------------ ------------
3950953118 1 EHR EHRDG Hexindai-BJ-
XXY-80
* 2082231315 1 PROD1 PROD1 edbjr2p1
2082231315 1 PROD1 PROD1 enmoedu1.exa
mple.com
Enter value for dbid: 3950953118
Using 3950953118 for database Id
Enter value for inst_num:
Using for instance number
:inst_num := ;
*
ERROR at line 3:
ORA-06550: line 3, column 18:
PLS-00103: Encountered the symbol ";" when expecting one of the following:
( - + case mod new not null <an identifier>
<a double-quoted delimited-identifier> <a bind variable>
continue avg count current exists max min prior sql stddev
sum variance execute forall merge time timestamp interval
date <a string literal with character set specification>
<a number> <a single-quoted SQL string> pipe
<an alternatively-quoted string literal with character set specification>
<an alternatively
declare
*
ERROR at line 1:
ORA-20200: Database/Instance / does not exist in DBA_HIST_DATABASE_INSTANCE
ORA-06512: at line 23
解决:
这是由于sqlplus环境变量配置导致输入的dbid位数过长无法识别
SQL> show numformat
numformat "999,999,999,999"
将numformat设置为默认
SQL> set numformat ""
SQL> show numformat