0

I have following SQL running from a long time. I couldn't see the status When I tried to look the time remaining for the query to complete. Can someone explain me why I couldn't find the SQL status

insert into SCOTT.EMP select * from SCOTT.EMP@dblink;

Query used: SELECT USERNAME, sid, SERIAL#, OPNAME, to_char(start_time,'hh24:mi:ss') stime, message,( sofar/totalwork)* 100 percent FROM v$session_longops WHERE sofar/totalwork < 1;

Thanks in advance!

  • 1
    look in the database where @dblink is pointing to. – ik_zelf Jun 4 '14 at 7:55
1

The best view (for me) to see the status of a long query is V$SQL_MONITOR. This view include all query that has consumed at least 5 seconds of CPU or I/O time. This view is very volatile, so you have to answer it faster after it's execution. If you can't find it into this view, you can find it in a awr report

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.