다음을 통해 공유


Microsoft.SqlServer.Management.Dac 네임스페이스

The Microsoft.SqlServer.Management.Dac namespace contains classes that represent the Dac objects. The top-level instance is called DacStore and provides the connection to SQL Server. The Dac objects can be used to create and manage a DAC package, which contains all the information required to re-create a data-tier application.

The Microsoft.SqlServer.Management.Dac namespace contains the DAC objects. The DAC objects are used together with the Microsoft.SqlServer.Managment.Smo, Microsoft.SqlServer.Managment.Dmf, and Microsoft.SqlServer.Managment.Utility namespaces to create DAC packages. The DAC packages can be installed on an instance of SQL Server using the DAC object model, or deployed onto the SQL Server Utility using the SQL Server Utility object model. In Design mode, SMO is not connected to an instance of SQL Server. The SMO objects are used to design a data-tier application structure which can be saved into the DAC package. A DAC package can also include a limited amount of reference data and some miscellaneous files. Policy information is stored for each SMO instance class, and for the overall instance of SQL Server using DMF conditions. After it is created, the DAC package can be used to install the data-tier application on an instance of SQL Server that meets the specified DMF conditions. In connected mode, the SMO Server object represents an instance of SQL Server.

The Microsoft.SqlServer.Management.Dac namespace resides in the Microsoft.SqlServer.Management.Dac.dll file. Additionally, some of the enumeration classes are in the Microsoft.SqlServer.Management.DacEnum.dll files. You must import both files to access the classes in the Microsoft.SqlServer.Management.Dac namespace. In addition, you must import the Microsoft.SqlServer.Managment.Smo, Microsoft.SqlServer.Managment.Dmf, and Microsoft.SqlServer.Managment.Sdk.Sfc namespaces to create a DAC package.

By using the Microsoft.SqlServer.Management.Dac namespace, you can do the following:

  • Create an object graph that represents the data-tier application structure.

  • Add reference data.

  • Add miscellaneous files

  • Add deployment conditions.

  • Add configuration conditions.

  • Install the DAC package.

  • Upgrade a DAC package.

  • Create a DAC package.

  • Load and save a DAC package from file (serialize and deserialize).

클래스

  클래스 설명
공용 클래스 ActionNotSupportedException The ActionNotSupportedException class is used to raise an exception when the requested data-tier action, such as upgrade or register, is not supported by the version of the Database Engine the application is connected to.
공용 클래스 BinarySourceBase The BinarySourceBase type is a base class that provides access to the IBinarySource interface.
공용 클래스 ConnectionNotSetException The ConnectionNotSetException class is used to raise an exception when the connection passed to a DAC action, such as install, upgrade, or uninstall.
공용 클래스 DacActionEventArgs 배포 및 제거 중 DAC 동작 단계에서 이벤트가 발생할 때 전송되는 데이터를 나타냅니다.
공용 클래스 DacActionValidator Validates that the requirements of the DAC action (install, upgrade, or uninstall) are in place.
공용 클래스 DacCompilationError The CompilationError class represents an error generated when the DAC package is being compiled.
공용 클래스 DacCompilationErrorCollection The DacCompilationErrorCollection type stores a collection of DAC compilation errors.
공용 클래스 DacCompilationResult The DacCompilationResult class represents the DAC package and the collection of errors generated by compiling it.
공용 클래스 DacCompilationUnit The DacCompilationUnit accepts Transact-SQL content and compiles it into a data-tier application (DAC) type. Any Transact-SQL file can be added or removed prior to compilation. 
공용 클래스 DacConfig The DacConfig class returns data-tier application (DAC) configuration information.
공용 클래스 DacDatabaseInformation The DacDatabaseInformation object stores information about data-tier application (DAC) actions that can be performed on a database.
공용 클래스 DacDomain The DacDomain class instantiates the Microsoft.SqlServer.Management.Sdk.Sfc methods and properties inherited by the DacStore class.
공용 클래스 DacDomain. . :: . .Key The DacDomain..::..Key class contains the key that identifies the DacDomain class.
공용 클래스 DacException The DacException class is a generic exception that is raised when an error occurs using the Microsoft.SqlServer.Management.Dac namespace.
공용 클래스 DacExtractionException The DacExtractionException class is a an exception that is raised when an error occurs during extraction of a DAC package.
공용 클래스 DacExtractionUnit The DacExtractionUnit class contains the information that must be extracted to a DAC type, such as server graphs and miscellaneous files.
공용 클래스 DacExtractValidationResult The DacExtractValidationResult object represents the result of extracting objects from a DAC package.
공용 클래스 DacInstance The DacInstance type stores metadata information, such as the instance name and date created, about a deployed instance of a data-tier application (DAC).
공용 클래스 DacInstance. . :: . .Key The DacInstance..::..Key class represents the key that identifies the DacInstance class.
공용 클래스 DacInstanceCollection The DacInstanceCollection type stores one or more DAC instances contained in an instance of the Database Engine.
공용 클래스 DacServerInformation The DacServerInformation class specifies the level of support for data-tier application (DAC) operations, such as upgrade, in an instance of the Database Engine.
공용 클래스 DacStore DacStore 유형은 DAC 개체 모델의 루트이며 DAC 인스턴스 컬렉션의 루트입니다.
공용 클래스 DacType DacType 클래스는 특정 응용 프로그램을 지원하기 위해 개발하여 배포한 데이터 계층 개체, 정책 및 속성의 집합을 나타냅니다.
공용 클래스 DacUpgradeOptions DAC 인스턴스를 업그레이드할 때 사용되는 옵션을 지정하려면 이 형식을 사용합니다.
공용 클래스 DacUpgradeResult The DacUpgradeResult class records information about the results of upgrading a DAC instance.
공용 클래스 DatabaseDeploymentProperties The DatabaseDeploymentProperties object represents the properties of a deployed database.
공용 클래스 DatabaseExtractValidator Validates that the database can be extracted.
공용 클래스 DeploymentValidationException The DeploymentValidationException class represents an exception thrown during DAC deployment due to a validation error.
공용 클래스 DesignModeServerExtractException The DesignModeServerExtractException class represents an exception that is raised the server containing the database specified in an extract operation is in Design mode.
공용 클래스 ExtractValidationException The ExtractValidationException class represents an exception thrown during a validation operation.
공용 클래스 FailedTargetSelectionException The FailedTargetSelectionException class represents an exception that is thrown when target selection policy fails during deployment of a DAC.
공용 클래스 FileExtraSource The FileSource type represents a miscellaneous file that is included in the DAC package.
공용 클래스 InvalidaDACTypeCredentialsException The InvalidDacTypeCredentialsException class is an exception that is raised when upgrading a DAC if the credentials of the new DAC type do not match the credentials of the current DAC instance.
공용 클래스 InvalidaDatabaseStateException The InvalidDatabaseStateException class is an exception that is raised when a database is in a state that cannot support a requested data-tier application (DAC) action, such as deploy or upgrade.
공용 클래스 InvalidDatabaseExtractException The DatabaseExtractException class is an exception that is raised when the database specified in an extract operation is invalid.
공용 클래스 InvalidDatabaseStateForExtractException 데이터베이스 상태 때문에 추출 작업을 수행할 수 없을 때 발생합니다.
공용 클래스 InvalidInputException The InvalidInputException class is raised when validation of input data fails in the DAC package.
공용 클래스 MiscellaneousFilesCollection The MiscellaneousFilesCollection class contains a collection of files to be added to the DAC package.
공용 클래스 MissingDacSchemaException The MissingDacSchemaException class is an exception that is raised during validation when the DAC schema is missing.
공용 클래스 MissingExtractServerPermissionsException The MissingExtractServerPermissionsException class represents an exception that is raised during extraction when the caller has insufficient permissions on the server to extract the database.
공용 클래스 MissingServerPermissionsException The MissingServerPermissionsException class represents an exception that is raised when the caller has insufficient permissions on the server to deploy the DAC.
공용 클래스 MissingServerPermissionsForRePartException The MissingServerPermissionsForRePartException class represents an exception that is raised when the caller does not have sufficient permissions
공용 클래스 ServerDeploymentValidator The ServerDeploymentValidator class validates that the specified database engine is able to be used as a DAC store.
공용 클래스 SmoBuilder The SmoBuilder class defines the GetSmoHierarchy method, which generates the SMO server hierarchy from binder metadata.
공용 클래스 SourceInfo The SourceInfo class represents a location in a DAC source file that has thrown an exception.
공용 클래스 TSqlCompilationErrorCollection The TSqlCompilationErrorCollection class represents a collection of TSqlCompilationError objects.
공용 클래스 TSqlCompilationException The TSqlCompilationException class represents an exception that is thrown during Transact-SQL compilation.
공용 클래스 TSqlCompilationResult The TSqlCompilationResult class defines methods and properties that contain information about the result of a Transact-SQL compilation.
공용 클래스 TSqlSourceFile The TSqlSourceFile class represents a Transact-SQL source file.
공용 클래스 ValidatedObject The ValidatedObject class describes objects that have been validated.
공용 클래스 ValidatedObjectEventArgs Represents an object that was validated as part of a data-tier application (DAC) action, such as deploy or delete.

구조

  구조 설명
공용 구조 Location Represents the location of the source of the error in the Transact-SQL input files to the DAC compilation unit.
공용 구조 TSqlCompilationError The TSqlCompilationError class contains information on a Transact-SQL compilation error or warning.

인터페이스

  인터페이스 설명
공용 인터페이스 IBinarySource The IBinarySource type is an interface that provides access to an I/O file stream.
공용 인터페이스 IExtraSource The IExtraSource type is an interface that provides I/O stream access to a miscellaneous file in the DAC package.
공용 인터페이스 ISizeItem Defines an interface that allows the implementing class to calculate its size.

열거형

  열거형 설명
공용 열거형 ActionName ActionName 열거형은 가능한 각 동작 단계의 이름을 열거합니다.
공용 열거형 ActionState The ActionState enumeration lists the possible DAC action step states.
공용 열거형 DacExceptionType The DacExceptionType enumeration contains values that are used to specify the type of DAC exception.
공용 열거형 DacUninstallMode The DacUninstallMode enumeration contains values that are used to specify what to do with the database associated with a DAC instance when the instance is uninstalled.
공용 열거형 DatabaseState DAC 데이터베이스의 가능한 상태를 열거합니다.
공용 열거형 MessageLevel 이 열거형은 이벤트 인수의 메시지 수준을 나타냅니다. 이벤트 유형에 따라 인수에 주석이 추가됩니다.
공용 열거형 ObjectValidationResult An enumeration that specifies the values for reporting the results of validating or extracting an object.