Did you know that the catalog views in SQL Server 2005 exposes metadata for various objects in a database and at the server-level? This is the preferred method of accessing metadata. It is a much richer mechanism that doesn’t require access to system tables or undocumented columns or status bits. If you want standard and portable access to metadata then you can still use the INFORMATION_SCHEMA views but it is limited to standard specific features, data types and views.


I have posted several topics in the past that shows how to use the information in various catalog views. And the Books Online Documentation has a topic that has answers to several frequently asked questions. It shows you how to use the catalog views to get answers to following questions for example:



You can find the topic using the links below:


Books Online Client: ms-help://MS.SQLCC.v9/MS.SQLSVR.v9.en/udb9/html/ca202580-c37e-4ccd-9275-77ce79481f64.htm


Please check it out and send your feedback using the Books Online feedback mechanism if you want to see additional questions. You can also post such questions here and I will write the queries using the catalog views.



Read full article…