Export (0) Print
Expand All
ABS
ALL
AND
ANY
AVG
bit
COS
COT
DAY
EXP
GO
IN
LEN
LOG
MAX
MIN
NOT
OR
PI
SET
SIN
STR
SUM
TAN
USE
VAR
Expand Minimize

@@IDLE

SQL Server 2000

Returns the time in milliseconds (based on the resolution of the system timer) that Microsoft® SQL Server™ has been idle since last started.

Syntax

@@IDLE

Return Types

integer

Remarks

To display a report containing several SQL Server statistics, run sp_monitor.

Examples

This example shows the number of milliseconds SQL Server was idle between the start time and the current time.

SELECT @@IDLE AS 'Idle ms', GETDATE() AS 'As of'

Here is the result set:

Idle Ms              As of
-----------------    ---------------------------
277593               1998-04-18  16:41:07.160

See Also

@@CPU_BUSY

sp_monitor

@@IO_BUSY

System Statistical Functions

Was this page helpful?
(1500 characters remaining)
Thank you for your feedback
Show:
© 2014 Microsoft