I’ll admit it, there are times where detaching a database is the best way to get something accomplished, but it is my least favorite way of doing anything. Using this method can leave yourself open to issues, such as security, if things go wrong. I think that it’s an important aspect that people miss when detaching a database.
When you detach the database, SQL Server essentially looses all knowledge of it. If SQL Server is no longer aware of the database, what SQL Server based scripts or tools can you use against that database? The answer… None. Zip. Nada. Zero. In other words, you can’t. All of those handy DMV or DBCC scripts will not work.