-
finding last dml done in database
is there a command to find out what was the last dml statement done in the database ?
-
I think slothfur asking last sql statement(dml) executed in the database.
slothfur,
If it's correct then try to use logminer, If you add the current
log file and if you select based on date, Then you may able to get
last sql statement informaiton.
If you are intrested on logminer then let me know, I can help you some more.
Good Luck.
Sree.
sree
-
Try the follsowing query.
select a.address,a.PIECE,a.sql_text ,b.logon_time from v$sqltext a,v$session b
where b.sql_address=a.ADDRESS
and trunc(logon_time) =trunc(sysdate)
order by a.address,a.PIECE ,b.logon_time
-
It can be as simple as this :
select sql_text, hash_value, first_load_time from V$sqlarea order by first_load_time desc ;
This should give you all latest SQL that ran in the database..
In case you want to dig deep, get the hash value and find in sql_text as
select sql_text fromk v$sql_text where hash_value = &hash_value order by piece;
OCP 8.0, 8i, 9i
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|