当前位置:网站首页>Oracle common SQL
Oracle common SQL
2022-07-02 03:33:00 【Tiantian code code Tiantian】
1. View servers IP
select UTL_INADDR.get_host_address() from dual;
2. Current session host IP
select sys_context('USERENV', 'IP_ADDRESS') from dual3. Server hostname
SELECT host_name from v$instance;
4. Current session hostname
select sys_context('USERENV', 'HOST') from dual;5. Query server platform information
SELECT * FROM DBA_REGISTRY_DATABASE;6. Query the memory size of the server
SELECT value / 1024 / 1024 / 1024 G
FROM v$osstat
where stat_name = 'PHYSICAL_MEMORY_BYTES'
7. View control information
select name from v$controlfile;
8. View data files
select file_name from dba_data_files;
9. view log file
select member from v$logfile;
10. View temporary files
select file_name from Dba_temp_files;11. see archive log
select name from v$archived_log12. Query current user
show user13. Query all tables of the current user
select unique tname from col;
-- perhaps
select * from user_tables;
-- perhaps
select * from tab;14. Check the database creation time
SELECT TO_CHAR(CREATED, 'YYYY-MM-DD,HH24:MI:SS'), LOG_MODE FROM V$DATABASE;15. View data objects
select owner, object_type, status, count(*) count#
from all_objects
group by owner, object_type, status;16. Check the number of connections for different users
select username, count(username)
from v$session
where username is not null
group by username;
边栏推荐
- Oracle 常用SQL
- Basic syntax of unity script (6) - specific folder
- Comment élaborer une stratégie nuageuse à l'ère des nuages mixtes
- Learn PWN from CTF wiki - ret2shellcode
- 蓝桥杯单片机省赛第十一届第二场
- aaaaaaaaaaaaa
- Halcon image rectification
- Unity脚本的基础语法(8)-协同程序与销毁方法
- What is the binding path of SAP ui5
- 高性能 低功耗Cortex-A53核心板 | i.MX8M Mini
猜你喜欢

高性能 低功耗Cortex-A53核心板 | i.MX8M Mini

Review materials of project management PMP high frequency examination sites (8-1)

Verilog timing control

How to do medium and long-term stocks, and what are the medium and long-term stock trading skills?

《MATLAB 神经网络43个案例分析》:第41章 定制神经网络的实现——神经网络的个性化建模与仿真

MySQL之账号管理

Exchange rate query interface

Pointer array & array pointer

"Analysis of 43 cases of MATLAB neural network": Chapter 42 parallel operation and neural network - parallel neural network operation based on cpu/gpu

Verilog 状态机
随机推荐
What do you know about stock selling skills and principles
Docker安装canal、mysql进行简单测试与实现redis和mysql缓存一致性
Global and Chinese market of gynaecological health training manikin 2022-2028: Research Report on technology, participants, trends, market size and share
Global and Chinese markets for welding equipment and consumables 2022-2028: Research Report on technology, participants, trends, market size and share
Kotlin basic learning 15
aaaaaaaaaaaaa
VS2010插件NuGet
leetcode-1380. Lucky number in matrix
Yan Rong looks at how to formulate a multi cloud strategy in the era of hybrid cloud
Comment élaborer une stratégie nuageuse à l'ère des nuages mixtes
KL divergence is a valuable article
焱融看 | 混合云时代下,如何制定多云策略
Global and Chinese market of X-ray detectors 2022-2028: Research Report on technology, participants, trends, market size and share
Halcon image rectification
In wechat applet, the externally introduced JS is used in xwml for judgment and calculation
[designmode] builder model
High performance and low power cortex-a53 core board | i.mx8m Mini
Kotlin基础学习 17
一天上手Aurora 8B/10B IP核(5)----从Framing接口的官方例程学起
Haute performance et faible puissance Cortex - A53 Core Board | i.mx8m mini