It has been a while since last post now due to summer vacation and busy working hours
In my post on simple database activity monitoring, I described a method by calculating periodical values for read write operations for databases. These values are calculated based on DMVs (Dynamic Management Views) that stored performance counters. The problem is that most of these DMVs is reset when the SQL Service or the server isself is restarted.
SELECT login_time FROM sysprocesses WHERE spid = 1
SELECT sqlserver_start_time FROM sys.dm_os_sys_info
SELECT [crdate] AS [LastStartupDate] FROM [dbo].[sysdatabases] WHERE [name] ='tempdb' AND [crdate] < GETDATE()