September 7, 2007 at 7:34 am
Is there a function or way to determine how many seconds have have gone by since server startup. @@?
I need to calculated some stuff with sys.dm_os_performance_counters and I think the operations/sec counters are cummulative.
Thanks
-WM
September 7, 2007 at 7:40 am
You can calculate the uptime using the sysprocesses.
select
DateDiff(ss,login_time, getdate())
from sysprocesses
where spid = 1
Markus
[font="Verdana"]Markus Bohse[/font]
September 7, 2007 at 7:45 am
thanks
In addition to that are there any other functions that contain this info?
-WM
September 7, 2007 at 8:42 am
Since you're using DMVs, I'm assuming this is on SS2005. If so, does the following return what you want?
SELECT
ms_ticks / 1000 FROM sys.dm_os_sys_info
September 7, 2007 at 8:49 am
That's what I was looking for thanks
-WM
Viewing 5 posts - 1 through 4 (of 4 total)
You must be logged in to reply to this topic. Login to reply
This website stores cookies on your computer.
These cookies are used to improve your website experience and provide more personalized services to you, both on this website and through other media.
To find out more about the cookies we use, see our Privacy Policy