1
1
、查询oracle的连接数
2
select
count
(
*
)
from
v$session;
3
2
、查询oracle的并发连接数
4
select
count
(
*
)
from
v$session
where
status
=
'
ACTIVE
'
;
5
3
、查看不同用户的连接数
6
select
username,
count
(username)
from
v$session
where
username
is
not
null
group
by
username;
7
4
、查看所有用户:
8
select
*
from
all_users;
9
5
、查看用户或角色系统权限(直接赋值给用户或角色的系统权限):
10
select
*
from
dba_sys_privs;
11
select
*
from
user_sys_privs;
12
6
、查看角色(只能查看登陆用户拥有的角色)所包含的权限
13
select
*
from
role_sys_privs;
14
7
、查看用户对象权限:
15
select
*
from
dba_tab_privs;
16
select
*
from
all_tab_privs;
17
select
*
from
user_tab_privs;
18
8
、查看所有角色:
19
select
*
from
dba_roles;
20
9
、查看用户或角色所拥有的角色:
21
select
*
from
dba_role_privs;
22
select
*
from
user_role_privs;
23
10
、查看哪些用户有sysdba或sysoper系统权限(查询时需要相应权限)
24
select
*
from
V$PWFILE_USERS;
![查看oracle数据库的连接数以及用户](http://www.blogjava.net/Images/OutliningIndicators/None.gif?x-oss-process=image/resize,w_1400/format,webp)
2
![查看oracle数据库的连接数以及用户](http://www.blogjava.net/Images/OutliningIndicators/None.gif?x-oss-process=image/resize,w_1400/format,webp)
3
![查看oracle数据库的连接数以及用户](http://www.blogjava.net/Images/OutliningIndicators/None.gif?x-oss-process=image/resize,w_1400/format,webp)
4
![查看oracle数据库的连接数以及用户](http://www.blogjava.net/Images/OutliningIndicators/None.gif?x-oss-process=image/resize,w_1400/format,webp)
5
![查看oracle数据库的连接数以及用户](http://www.blogjava.net/Images/OutliningIndicators/None.gif?x-oss-process=image/resize,w_1400/format,webp)
6
![查看oracle数据库的连接数以及用户](http://www.blogjava.net/Images/OutliningIndicators/None.gif?x-oss-process=image/resize,w_1400/format,webp)
7
![查看oracle数据库的连接数以及用户](http://www.blogjava.net/Images/OutliningIndicators/None.gif?x-oss-process=image/resize,w_1400/format,webp)
8
![查看oracle数据库的连接数以及用户](http://www.blogjava.net/Images/OutliningIndicators/None.gif?x-oss-process=image/resize,w_1400/format,webp)
9
![查看oracle数据库的连接数以及用户](http://www.blogjava.net/Images/OutliningIndicators/None.gif?x-oss-process=image/resize,w_1400/format,webp)
10
![查看oracle数据库的连接数以及用户](http://www.blogjava.net/Images/OutliningIndicators/None.gif?x-oss-process=image/resize,w_1400/format,webp)
11
![查看oracle数据库的连接数以及用户](http://www.blogjava.net/Images/OutliningIndicators/None.gif?x-oss-process=image/resize,w_1400/format,webp)
12
![查看oracle数据库的连接数以及用户](http://www.blogjava.net/Images/OutliningIndicators/None.gif?x-oss-process=image/resize,w_1400/format,webp)
13
![查看oracle数据库的连接数以及用户](http://www.blogjava.net/Images/OutliningIndicators/None.gif?x-oss-process=image/resize,w_1400/format,webp)
14
![查看oracle数据库的连接数以及用户](http://www.blogjava.net/Images/OutliningIndicators/None.gif?x-oss-process=image/resize,w_1400/format,webp)
15
![查看oracle数据库的连接数以及用户](http://www.blogjava.net/Images/OutliningIndicators/None.gif?x-oss-process=image/resize,w_1400/format,webp)
16
![查看oracle数据库的连接数以及用户](http://www.blogjava.net/Images/OutliningIndicators/None.gif?x-oss-process=image/resize,w_1400/format,webp)
17
![查看oracle数据库的连接数以及用户](http://www.blogjava.net/Images/OutliningIndicators/None.gif?x-oss-process=image/resize,w_1400/format,webp)
18
![查看oracle数据库的连接数以及用户](http://www.blogjava.net/Images/OutliningIndicators/None.gif?x-oss-process=image/resize,w_1400/format,webp)
19
![查看oracle数据库的连接数以及用户](http://www.blogjava.net/Images/OutliningIndicators/None.gif?x-oss-process=image/resize,w_1400/format,webp)
20
![查看oracle数据库的连接数以及用户](http://www.blogjava.net/Images/OutliningIndicators/None.gif?x-oss-process=image/resize,w_1400/format,webp)
21
![查看oracle数据库的连接数以及用户](http://www.blogjava.net/Images/OutliningIndicators/None.gif?x-oss-process=image/resize,w_1400/format,webp)
22
![查看oracle数据库的连接数以及用户](http://www.blogjava.net/Images/OutliningIndicators/None.gif?x-oss-process=image/resize,w_1400/format,webp)
23
![查看oracle数据库的连接数以及用户](http://www.blogjava.net/Images/OutliningIndicators/None.gif?x-oss-process=image/resize,w_1400/format,webp)
24
![查看oracle数据库的连接数以及用户](http://www.blogjava.net/Images/OutliningIndicators/None.gif?x-oss-process=image/resize,w_1400/format,webp)