goprasad
asked on
TSQL script to identify which DB's are active in last 60 days, in SQL server 2005 instance
Hello there,
Please advise TSQL script to identify which DB's are active in last 60 days, in SQL server 2005 instance?
Thanks and Regards
Please advise TSQL script to identify which DB's are active in last 60 days, in SQL server 2005 instance?
Thanks and Regards
ASKER
Please advise
What do you mean by active?
ASKER
To know if there has been any activity in DB level in last 60 days, so that we determine how many dB's are being actually used.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
In that case, based on the last mdf modified date, can we assume that the db is in use?
Please advise.
Please advise.
ASKER
Please advise.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
So what's the solution? Do you think, by changing the mode to Single User and generate call to Service Desk is the way to find out?
Please advise.
Please advise.
You could set the db(s) OFFLINE and see if any errors are generated.
You could run a trace that captures database names for all SQL procs and queries.
You could run a trace that captures database names for all SQL procs and queries.
ASKER
How to run a trace using SQL profiler that captures all the transactions for all the databases in the instance.
ASKER