记录下经常要用的sql
SELECT DB_NAME(er.[database_id]) [DatabaseName], er.[command] AS [CommandType], er.[percent_complete], er.start_time, CONVERT(DECIMAL(5, 2), er.[percent_complete]) AS [Complete_Percent] ,CONVERT(DECIMAL(38, 2), er.[total_elapsed_time] / 60000.00) AS [ElapsedTime_m] ,CONVERT(DECIMAL(38, 2), er.[estimated_completion_time] / 60000.00) AS [EstimatedCompletionTime_m] FROM sys.dm_exec_requests AS er WHERE --DB_NAME(er.[database_id]) in ('xxxx') and er.[command] in ( 'RESTORE DATABASE' ,'BACKUP DATABASE') order by er.start_time desc
在网上找的sql
————————————————
原文链接:https://blog.csdn.net/xiaoye1202/article/details/111885930
标签:DECIMAL,CONVERT,DB,备份,sqlserver,id,time,数据库,er From: https://www.cnblogs.com/tfsys/p/16795085.html