2 Star 0 Fork 0

mirrors_ReneNyffenegger/fatdba-Oracle-Database-Scripts

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
racdbstatus.sql 1.89 KB
一键复制 编辑 原始数据 按行查看 历史
Prashant Dixit 提交于 2021-12-10 15:00 . Create racdbstatus.sql
PROMPT
PROMPT
PROMPT~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
PROMPT------ /) (\
PROMPT------ .-._((,~~.))_.-,
PROMPT------ `-. @@ ,-'
PROMPT------ / ,o--o. \
PROMPT------ ( ( .__. ) )
PROMPT------ ) `----' (
PROMPT------ / \
PROMPT------ / \
PROMPT------ / \
PROMPT------ "The Silly Cow"
PROMPT----- Script: racdbstatus.sql
PROMPT----- Author: Prashant 'The FatDBA'
PROMPT----- Cat: Performance Management and Issue Identification
PROMPT----- Version: V1.2 (Date: 04-02-2020)
PROMPT-----
PROMPT-----
PROMPT-----
PROMPT~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~COLUMN instance_name FORMAT a13 HEAD 'Instance|Name / Number'
COLUMN thread# FORMAT 99999999 HEAD 'Thread #'
COLUMN host_name FORMAT a28 HEAD 'Host|Name'
COLUMN status FORMAT a6 HEAD 'Status'
COLUMN startup_time FORMAT a20 HEAD 'Startup|Time'
COLUMN database_status FORMAT a8 HEAD 'Database|Status'
COLUMN archiver FORMAT a8 HEAD 'Archiver'
COLUMN logins FORMAT a10 HEAD 'Logins?'
COLUMN shutdown_pending FORMAT a8 HEAD 'Shutdown|Pending?'
COLUMN active_state FORMAT a6 HEAD 'Active|State'
COLUMN version HEAD 'Version'
SELECT
instance_name || ' (' || instance_number || ')' instance_name
, thread#
, host_name
, status
, TO_CHAR(startup_time, 'DD-MON-YYYY HH:MI:SS') startup_time
, database_status
, archiver
, logins
, shutdown_pending
, active_state
, version
FROM
gv$instance
ORDER BY
instance_number;
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/mirrors_ReneNyffenegger/fatdba-Oracle-Database-Scripts.git
git@gitee.com:mirrors_ReneNyffenegger/fatdba-Oracle-Database-Scripts.git
mirrors_ReneNyffenegger
fatdba-Oracle-Database-Scripts
fatdba-Oracle-Database-Scripts
main

搜索帮助