SQL> select * from t where object_id=1060;
OBJECT_ID OWNER
---------- ------------------------------
1060 SYSTEM
SQL> alter system flush shared_pool;
系统已更改。
SQL> /
系统已更改。
SQL> oradebug setmypid
已处理的语句
SQL> ALTER SESSION SET EVENTS 'immediate trace name library_cache level 4';
会话已更改。
SQL> SQL> oradebug tracefile_name
/oracle/app/oracle/diag/rdbms/june/june/trace/june_ora_31889.trc
Bucket: #=122703 Mutex=289ca8bc(110000, 3, 0, 6)
LibraryHandle: Address=319948d8 Hash=f5c1df4f LockMode=N PinMode=0 LoadLockMode=0 Status=VALD
ObjectName: Name=select * from t where object_id=1060
FullHashValue=d30c91e81a0f4275e4969685f5c1df4f Namespace=SQL AREA(00) Type=CURSOR(00)
Identifier=4123123535 OwnerIdn=91
Statistics: InvalidationCount=0 ExecutionCount=1 LoadCount=2 ActiveLocks=1 TotalLockCount=1
TotalPinCount=1
Counters: BrokenCount=1 RevocablePointer=1 KeepDependency=1 KeepHandle=1 BucketInUse=0 HandleInUse=0
Concurrency: DependencyMutex=31994940(0, 0, 0, 0) Mutex=3199498c(17, 18, 0, 6)
Flags=RON/PIN/TIM/PN0/DBN/[10012841]
WaitersLists:
Lock=31994930[31994930,31994930]
Pin=31994938[31994920,31994920]
Timestamp: Current=02-25-2014 14:54:02
LibraryObject: Address=2572b034 HeapMask=0000-0001-0001 Flags=EXS[0000] Flags2=[0000] PublicFlags=
[0000]
ChildTable: size='16'
Child: id='0' Table=2572bfb0 Reference=2572b63c Handle=319b004c
NamespaceDump:
Parent Cursor: sql_id=f95nqhruw3rug parent=0x2572b0b8 maxchild=1 plk=y ppn=n
SQL> select sql_text from v$sql where hash_value=to_number('f5c1df4f','xxxxxxxx');
SQL_TEXT
--------------------------------------------------------------------------------
select * from t where object_id=1060
SQL> select sql_text,hash_value,address from v$sql where hash_value=to_number('f5c1df4f','xxxxxxxx');
SQL_TEXT HASH_VALUE ADDRESS
---------------------------------------- ---------- --------
select * from t where object_id=1060 4123123535 319948D8
这里我们再进行level 8的dump:
SQL> oradebug setmypid
已处理的语句
SQL> ALTER SESSION SET EVENTS 'immediate trace name library_cache level 8';
会话已更改。
SQL> oradebug tracefile_name