Need help in getting query execution time from Enterprise manager
Need help in getting query execution time from Enterprise manager
I'll see if I can drag something out of my notes / books tomorrow. I don't use OEM much but I presume you're trying to find out which queries are using the most resource rather than simply timing a piece of SQL? Also - which version - 11g?
Edit: a bit more googling helped:
http://download.oracle.com/docs/cd/B...dppt_sqlid.htm
I tried that but it's absolutely useless.
Say, I runa query SELECT * FROM CUSTOMERS, this isn't caught and the timing isn't shown. Few mins. later, you get afigure but if yu check the SQL statement, it's for a different internal work and not my statement. Gonna try using SET TIMING ON and get result in ms.
If you're trying to debug an individual statement you probably want to use autotrace ("set autotrace on") or run an explain plan, not just time it.
My Oracle skills are a bit rusty and I did everything using SQL Plus but simple 'set timing on' followed by your query should give you what you want.
What platform are you running Oracle on? With timing it's important to use the correct version of SQL Plus for the version of Oracle so probably best to run the command on the box itself if you can. Also the format of the answer varies depending on what platform you're using and timing can be a bit broken on Windows.
You should be able to use 'help timing' in SQL Plus to get some pointers.
There are currently 1 users browsing this thread. (0 members and 1 guests)