show con_name
/*
CON_NAME
------------------------------
CDB$ROOT
*/
--show pdbs
alter pluggable database orclpdb open;
/*
*/
alter session set container=orclpdb
/*
Session altered.
*/
show con_name
/*
CON_NAME
------------------------------
ORCLPDB
*/
select oracle_username, os_user_name, locked_mode, object_name, object_type
from v$locked_object a,dba_objects b
where a.object_id = b.object_id;
/*
no rows selected
*/
select * from hr.employees;
update hr.employees
set salary=salary+1
where employee_id=100;
/*
1 row updated.
*/
select oracle_username, os_user_name, locked_mode, object_name, object_type
from v$locked_object a,dba_objects b
where a.object_id = b.object_id;
/*
ORACLE_USERNAME OS_USER_NAME LOCKED_MODE OBJECT_NAME OBJECT_TYPE
-------------------- -------------------- ----------- -------------------- --------------------
SYS mike 3 EMPLOYEES TABLE
*/
rollback;
/*
Rollback complete.
*/
select oracle_username, os_user_name, locked_mode, object_name, object_type
from v$locked_object a,dba_objects b
where a.object_id = b.object_id;
/*
no rows selected
*/
'Database > Oracle' 카테고리의 다른 글
23 - [Oracle 19C] To query data files (0) | 2023.11.17 |
---|---|
22 - [Oracle 19C] to change container (cdb_, dba_) (0) | 2023.11.17 |
20 - [Oracle 19C] Common users VS local users (0) | 2023.11.17 |
19 - [Oracle 19C] Oracle Data Dictionary (0) | 2023.11.16 |
18 - [Oracle 19C] saving and running scripts (0) | 2023.11.16 |