经常和MV刷新打交道。用一个脚本监控刷新进度。

这个脚本很有用。记录一下。
col opname format a21
col target_desc format a32
col perwork format a12
col message format a83
set lines 131
select sid,OPNAME,sofar,TOTALWORK,trunc(sofar/totalwork*100,2)||'%' as perwork,elapsed_seconds,message
from v$session_longops where sofar!=totalwork;

你可能感兴趣的:(脚本)