In SQL Server 2005, can you easily determine the last time someone queried a database.
A:
Not easily, but if you turn on the logging feature of SQL Server you can examine the logs using software to discover when the last query was, and what it was.
Adam Davis
2009-04-02 20:14:21
+2
A:
You need to have auditing, or a sql server trace set up ahead of time.
Sam
2009-04-02 23:01:45
A:
SQL Server can log event information for logon attempts and you can view it by reviewing the errorlog. By turning on the auditing level of SQL Server.
follow these steps to enable auditing of all/successfull connections with Enterprise Manager in SQL Server:
Expand a server group. Right-click a server, and then click Properties. On the Security tab, under Audit Level, click all/success etc(required option).
You must stop and restart the server for this setting to take effect
sivaramakrishna
2009-04-03 07:10:46