Section 9.1. SMO Object Model

9.1. SMO Object Model

The SMO object model contains two types of classes:

Instance classes

Form a hierarchy that matches the database server object hierarchy. The top object is a SQL Server instance represented by the Server object. Under this object is a hierarchy of instance objects, including databases, tables, columns, indexes, and stored procedures. Instance classes are discussed in detail in Chapters 10 and 11.

Utility classes

Perform specific tasks and are independent of the server instance. Utility classes are discussed in detail in Chapters 12 and 13.

SMO has a collection of namespaces that represent different areas of functionality. These are described in Table 9-1.

Table 9-1. SMO namespaces




Classes common to SMO and Replication Management Objects (RMO)primarily classes used to establish a connection to a SQL Server instance


Classes used to develop and administer Notification Services instances and applications


Instance classes, utility classes, event handlers, exceptions, and enumerations used to programmatically control SQL Server


Classes that represent SQL Server Agent


Classes that represent Service Broker


Classes that represent Database Mail


Classes that represent registered servers and schemas


Classes that provides programmatic access to the WMI provider for Configuration Management


Classes that provide programmatic access for tracing and recording events, manipulating and analyzing trace logs, and replaying trace events

Programming SQL Server 2005
Programming SQL Server 2005
ISBN: 0596004796
EAN: 2147483647
Year: 2007
Pages: 147
Authors: Bill Hamilton © 2008-2017.
If you may any questions please contact us: