An error occurred while importing the exp logical backup file to the standby database. The error message is as follows:
- IMP-00017: The following statement failed due to Oracle error 6550:
- "Declare srec DBMS_STATS.STATREC; begin srec. MINVAL: = '00730068006f0075006"
- "C0075'; SREC. MAXVAL: = '9f9a00200020514b '; SREC. EAVS: = 4; SREC. CHVALS: = D"
- "BMS_STATS.CHARARRAY (utl_raw.cast_to_varchar2 ('00730068006f0075006c0075'), 'n"
- "FS [', utl_raw.cast_to_varchar2 ('4e5400200020664b'), utl_raw.cast_to_varchar2"
- "('4ed8002000204fca '), 'n character *', utl_raw.cast_to_varchar2 ('4efb002000205170'), 'n"
- "Comment ', 'O
- ......
- IMP-00003: encountered ORACLE error 6550
- ORA-06550: 1st rows, 4,836th columns:
- PLS-00103: The symbol "symbol ag? "When the following conditions are required:
- (-+ Case mod new not
- Null others <an identifier>
- <A double-quoted delimited-identifier> <a bind variable> 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
- <A character string with character set instructions that can be enclosed by quotation marks>
- <An SQL string with quotation marks>
This is a common import warning, usually related to the database/Client Version. For example, the source database and target database versions are both 10.2.0.4, but the client of 10.2.0.1 is used for export:
- Connect to: Oracle Database 10g Enterprise Edition Release 10.2.0.4.0-64bit Production
- With the Partitioning, Real Application Clusters, OLAP, Data Mining
- And Real Application Testing options
- EXPORT File Created by EXPORT: V10.02.01 in the normal path
In other projects, the same problem occurs when importing data from the 10.2.0.2 database to the 10.2.0.4 target database, regardless of the version of imp/exp.
The solution is to add a parameter to exp or imp to disable the export/import of statistics:Statistics = none
So what is the impact of not importing statistics. In fact, after 10 Gb of oracle, statistics are collected regularly by default. You can query this task in the dba_scheduler_jobs view: GATHER_STATS_JOB. You can also view the execution status in dba_scheduler_job_run_details.
Manual collection of statistics: Execute the dbms_scheduler.run_job ('gather _ STATS_JOB ') Stored Procedure (equivalent to the execution of statistics) in the sys user, and use gather_xxx_stats in the dbms_stats package to collect statistics. Disable the task of periodically collecting statistics: DBMS_SCHEDULER.DISABLE ('gather _ STATS_JOB ')
Modify the time policy for automatic collection of statistics in oracle 10 GB: log on to the system to execute the Stored Procedure dbms_scheduler.set_attribute. For example
Dbms_scheduler.set_attribute ('gather _ STATS_JOB ', 'schedule _ name', 'Maintenance _ WINDOW_GROUP ')
Dbms_scheduler.set_attribute ('weekend _ Window', 'duration', '+ 000 05:00:00 ')
Query:
- SelectD. window_name, d. repeat_interval, d. duration
- FromDBA_SCHEDULER_JOBS a, DBA_SCHEDULER_WINDOW_GROUPS B, DBA_SCHEDULER_WINGROUP_MEMBERS c, DBA_SCHEDULER_WINDOWS d
- WhereA. job_name ='Collect _ STATS_JOB'
- AndA. schedule_name = B. window_group_name
- AndB. window_group_name = c. window_group_name
- AndC. window_name = d. window_name
- Union All
- SelectD. window_name, d. repeat_interval, d. duration
- FromDBA_SCHEDULER_JOBS a, DBA_SCHEDULER_WINDOWS d
- WhereA. job_name ='Collect _ STATS_JOB'
- AndA. schedule_name = d. window_name;