SQL Server Management Objects (SMO)

The SQL Server Management Objects, known as SMO, is the management object model for SQL Server Yukon. SMO represents significant design and architecture improvements for the SQL Server management object model. It is a simple to use, but rich object model based on .NET managed code. SMO is the primary tool for developing database management applications using the .NET platform. SMO is used by every dialog in SQL Server "Workbench" and every administrative action you can perform in SQL Server "Workbench" can also be accomplished using SMO.

The new SMO object model and the WMI APIs replace SQL-DMO. Where possible, SMO incorporates similar objects as SQL-DMO for ease of use. You can still use SQL Server Yukon Beta 1 with SQL-DMO, but SQL-DMO will not be updated to manage Yukon-specific features.

SMO and SQL-DMO

The SMO object model is a logical continuation of the work done in SQL-DMO. SMO is feature-compatible with SQL-DMO, containing many of the same objects. Where possible, the original SQL-DMO design is followed but SMO has a number of additional features beyond SQL-DMO. To achieve maximum DDL and administrative coverage for SQL Server Yukon, SMO adds more than 150 new classes.

The primary advantages of SMO are in its performance and scalability. SMO has a cached object model, which allows you to change several properties of an object before effecting the changes to SQL Server. As a result, SMO makes fewer round trips to the server, and makes its objects more flexible. SMO also has optimized instantiation, meaning that you can partially or fully instantiate objects. You can load many objects quickly by not instantiating all properties of the objects.

Unlike SQL-DMO, which has a single Application root, that keeps references to all created Server objects, SMO lets you establish multiple roots for servers without establishing a new connection. SMO implements advanced multiple-phase scripting, in addition to supporting SQL-DMO style scripting. You can also switch an object into capture mode, and capture any DDL that would be emitted for that object, without actually applying changes to the server.

SQL-DMO also has a Managed Computer object which simplifies the interface to WMI, in order to support WMI monitoring and server configuration through the SMO object interface.

'programming > MSSQL' 카테고리의 다른 글

Windows 2003에서의 DTC(분산 트랜잭션) 관련 오류  (0) 2004.05.13
[Reference]SQL-DMO  (8) 2004.05.12
[세미나:03] 세미나 내용 정리  (0) 2004.05.10

+ Recent posts