• OCP-1Z0-053-V12.02-430题


    430.Which of the following is a prerequisite for running DBMS_TDB.CHECK_DB to a successful completion?

    A. The database must be in read-write mode.

    B. The database must have no external files.

    C. The database must open in read-only mode.

    D. The database must be mounted but not opened.

    Answer: C

    答案解析:

    参考:http://docs.oracle.com/cd/E11882_01/appdev.112/e40758/d_tdb.htm#ARPLS68864


    CHECK_DB Function

    This function checks whether a database can be transported to a target platform. It tests whether transport is supported at all for a given source and destination platform, and whether the database is currently in the correct state for transport.

    You can specify whether to skip checking parts of the database that are read-only or offline, if you do not plan to transport them.

    The function is overloaded. The different functionality of each form of syntax is presented along with the definition.

    Syntax

    DBMS_TDB.CHECK_DB (
         target_platform_name   IN VARCHAR2,
         skip_option            IN  NUMBER)
       RETURN BOOLEAN;
     
    DBMS_TDB.CHECK_DB (
         target_platform_name   IN VARCHAR2)
       RETURN BOOLEAN;
     
    DBMS_TDB.CHECK_DB
       RETURN BOOLEAN;

    Parameters

    Table 151-3 CHECK_DB Function Parameters

    Parameter Description

    target_platform_name

    The name of the destination platform, as it appears in V$DB_TRANSPORTABLE_PLATFORM.

    skip_option

    Specifies which, if any, parts of the database to skip when checking whether the database can be transported. Supported values are listed in Table 151-1, "DBMS_TDB Constants".


    Return Values

    If the database cannot be transported to the target platform or is not ready to be transported, returns FALSE. If the database is ready for transport, returnsTRUE.

    Usage Notes

    • If SERVEROUTPUT is ON, then the output will contain the reasons why the database cannot be transported and how to fix the problems. For details on possible reasons and fixes, see Table 151-4, "Reasons for CHECK_DB Function to Return FALSE".

      Table 151-4 Reasons for CHECK_DB Function to Return FALSE

      Cause Action

      Unrecognized target platform name.

      Check V$DB_TRANSPORTABLE_PLATFORM for recognized platform names.

      Target platform has a different endian format.

      Conversion is not supported.

      Database is not open read-only.

      Open database read-only and retry.

      There are active or in-doubt transactions in the database.

      Open the database read-write. After the active transactions are rolled back, open the database read-only and retry the operation.

      This situation can occur if users flash back the database and open it read only. The active transactions will be rolled back when the database is opened read-write.

      Deferred transaction rollback needs to be done.

      Open the database read-write and bring online the necessary tablespaces. Once the deferred transaction rollback is complete, open the database read-only and retry the operation.

      Database compatibility version is below 10.0.0.

      Change the COMPATIBLE initialization parameter to 10.0.0 or higher, open the database read-only, and retry the operation.

      Some tablespaces have not been open read-write with compatibility version is 10.0.0 or higher.

      Change the COMPATIBLE initialization parameter to 10.0.0 or higher, then open the affected tablespaces read-write. Shut down the database, open it read-only, and retry the operation.


    Examples

    This example illustrates the use of CHECK_DB with a database that is open read-write:

    SQL> SET SERVEROUTPUT ON
    SQL> DECLARE
           db_ready BOOLEAN;
         BEGIN
           db_ready := DBMS_TDB.CHECK_DB('Microsoft Windows IA (32-bit)');
         END;
         /
     
    Database is not open READ ONLY. Please open database READ ONLY and retry.
     
    PL/SQL procedure successfully completed.

     

     

  • 相关阅读:
    TT ERP 业务功能分析 汇总
    CSRedis 使用说明
    多线程,控制Task的20个并发数量,全部子线程执行完后,获取所有返回的值
    React 和 vue的区别以及React的环境搭建,运行
    jar 包上传后 Xshell启动
    FileZilla 上传文件
    vue多环境配置
    el-tree 节点常用操作
    钉钉微应用
    Bonobo Git Server
  • 原文地址:https://www.cnblogs.com/hzcya1995/p/13316439.html
Copyright © 2020-2023  润新知