Fetching metadata with SQL Server 2005

Fetching metadata is much more easier with SQL Server 2005 than it was with SQL Server 2000's esoteric system tables.

The system tables from previous versions of SQL Server are now implemented as a series of views called (appropriately enough) compatibility views. All of these views can be found in the sys schema.


Find all tables in a Database (Then-Now)

SQL SERVER 2000:
select name from sysobjects where type='U'

SQL SERVER 2005:
select name from sys.tables

Comments

Popular posts from this blog

Maven Crash Course - Learn Power Query, Power Pivot & DAX in 15 Minutes

"Data Prep & Exploratory Data Analysis" course by Maven Analytics

Oracle Cloud Infrastructure 2024 Generative AI Professional Course & Certification Exam (1Z0-1127-24)