我是靠谱客的博主 等待黑猫,最近开发中收集的这篇文章主要介绍ALTER DATABASE [NO] FORCE LOGGING,觉得挺不错的,现在分享给大家,希望可以做个参考。

概述

ALTER DATABASE [NO] FORCE LOGGING

Use this clause to put the database into or take the database out of FORCE LOGGING mode. The database must be mounted or open.

In FORCE LOGGING mode, Oracle Database logs all changes in the database except changes in temporary tablespaces and temporary segments. This setting takes precedence over and is independent of any NOLOGGING or FORCE LOGGING settings you specify for individual tablespaces and any NOLOGGING settings you specify for individual database objects.

If you specify FORCE LOGGING, then Oracle Database waits for all ongoing unlogged operations to finish.

See Also:

Oracle Database Administrator's Guide for information on when to use FORCE LOGGING mode

 

select log_mode,force_logging from v$database;
select tablespace_name,logging,force_logging from dba_tablespaces;
select table_name,logging from user_tables;
ALTER TABLESPACE users FORCE LOGGING;
ALTER DATABASE FORCE LOGGING;

 

$ sqlplus /nolog

SQL*Plus: Release 9.2.0.7.0 - Production on Sun Sep 1 20:37:48 2019

Copyright (c) 1982, 2002, Oracle Corporation.  All rights reserved.

SQL> conn / as sysdba
Connected.
SQL> select log_mode,force_logging from v$database;

LOG_MODE     FOR
------------ ---
ARCHIVELOG   NO

SQL> ALTER DATABASE FORCE LOGGING;

Database altered.

SQL> select log_mode,force_logging from v$database;

LOG_MODE     FOR
------------ ---
ARCHIVELOG   YES

SQL>

最后

以上就是等待黑猫为你收集整理的ALTER DATABASE [NO] FORCE LOGGING的全部内容,希望文章能够帮你解决ALTER DATABASE [NO] FORCE LOGGING所遇到的程序开发问题。

如果觉得靠谱客网站的内容还不错,欢迎将靠谱客网站推荐给程序员好友。

本图文内容来源于网友提供,作为学习参考使用,或来自网络收集整理,版权属于原作者所有。
点赞(40)

评论列表共有 0 条评论

立即
投稿
返回
顶部