Howdy.
Hey, I am writing a proc that will monitor database vitals. does anyone know how to tell if a database is in suspect mode from query analyzer? I imagine you should be able to tell from the status column in sysdatabases, but I cant seem to figure it out.
TIAHere's some info
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/trblsql/tr_servdatabse_494j.asp
and some more
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/tsqlref/ts_sys-d_5xrn.asp|||Type following on the SQL Query Analyser
USE <database_name>
SELECT DATABASEPROPERTY('<database_name>', 'IsSuspect')
Check result:
1 = TRUE
0 = FALSE
NULL = Invalid input
Hope this helps!!!!!
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment