├── .editorconfig ├── .gitattributes ├── .github └── workflows │ ├── ToolsConnectionInfo.xml │ └── pr-validation.yml ├── .gitignore ├── .gitmodules ├── CHANGELOG.md ├── CODE_OF_CONDUCT.md ├── Directory.Build.props ├── Directory.Build.rsp ├── Directory.Packages.props ├── LICENSE ├── Nuget └── CHANGELOG.md ├── README.md ├── SECURITY.md ├── SmoBuild ├── AssemblyInfo.props ├── CSharp.NetCore.props ├── CSharp.NetFx.props ├── CSharp.NetStandard.props ├── DdlEvents.targets ├── DdlEvents │ ├── class_template.cs │ ├── classenum_template.cs │ ├── eventsdef.cpp │ ├── eventsdef.txt │ ├── evtenum_template.cs │ ├── evtschema.pl │ ├── smoevt.pl │ ├── smoevt_template.cs │ ├── trc2evt.pl │ ├── trccomn.h │ ├── trccomn.txt │ ├── trcdef.cpp │ └── trcdef.txt ├── DisableStrongName.ps1 ├── SqlClientReference.props └── Version.props ├── azurepipelines-coverage.yml ├── dirs.proj ├── docs ├── README.md └── media │ └── certsettings.png ├── examples └── GetSmoObject │ ├── App.config │ ├── GetSmoObject.csproj │ ├── Program.cs │ ├── README.md │ └── SqlClientEventLogger.cs ├── global.json ├── init.cmd ├── packages └── .gitkeep └── src ├── Codegen ├── CodeGen.cs ├── ExecuteSqlFake.cs ├── ModelGen.cs ├── README.md ├── SmoCodeGen.csproj ├── StringEnumerator.cs ├── cfg.xml ├── collections_codegen.proj └── gen.xml ├── Directory.Build.props ├── Directory.Build.targets ├── FunctionalTest ├── Directory.Build.props ├── Dockerfiles │ └── 150Linux │ │ └── dockerfile ├── Framework │ ├── Helpers │ │ ├── AzureKeyVaultHelper.cs │ │ ├── AzureStorageHelper.cs │ │ ├── ConnectionHelpers.cs │ │ ├── ConnectionMetrics.cs │ │ ├── DataExtensions.cs │ │ ├── DatabaseObjectHelpers.cs │ │ ├── DirectoryHelpers.cs │ │ ├── ExceptionHelpers.cs │ │ ├── ExecutionManagerExtensions.cs │ │ ├── FabricDatabaseManager.cs │ │ ├── GenericSqlProxy.cs │ │ ├── PolicyStoreHelpers.cs │ │ ├── PropertyClasses.cs │ │ ├── RetryHelper.cs │ │ ├── ScriptHelpers.cs │ │ ├── ScriptSchemaObjectBaseHelpers.cs │ │ ├── ScriptTokenizer.cs │ │ ├── ServerObjectHelpers.cs │ │ ├── SmoObjectHelpers.cs │ │ ├── SqlClientEventRecorder.cs │ │ ├── SqlTestRandom.cs │ │ ├── SqlTypeConverterHelpers.cs │ │ ├── StringCollectionHelpers.cs │ │ ├── StringExtensions.cs │ │ ├── TSqlScriptingHelper.cs │ │ ├── TableExtensions.cs │ │ ├── TableObjectHelpers.cs │ │ ├── TestContextExtensions.cs │ │ ├── TraceHelper.cs │ │ └── XmlHelper.cs │ ├── Microsoft.SqlServer.Test.Manageability.Utils.csproj │ ├── PRVerification.runsettings │ ├── Scripts │ │ └── ValidateTableDataRetention_DataRetentionPeriodOption.sql │ ├── Sql2017Linux.runsettings │ ├── SqlVersion.cs │ ├── Sqlv150Linux.runsettings │ ├── Sqlv160Linux.runsettings │ ├── TestFramework │ │ ├── AlternateTestServerSource.cs │ │ ├── DatabaseHandlerBase.cs │ │ ├── DatabaseHandlerFactory.cs │ │ ├── DatabaseParameters.cs │ │ ├── DisconnectedTestAttribute.cs │ │ ├── FabricDatabaseHandler.cs │ │ ├── FabricWorkspaceDescriptor.cs │ │ ├── IDatabaseHandler.cs │ │ ├── RegularDatabaseHandler.cs │ │ ├── ReuseExistingDatabaseHandler.cs │ │ ├── ServerConnectionInfo.cs │ │ ├── SqlFeature.cs │ │ ├── SqlRequiredFeatureAttribute.cs │ │ ├── SqlTestAreaAttribute.cs │ │ ├── SqlTestBase.cs │ │ ├── SqlTestCategoryAttribute.cs │ │ ├── SqlTestDimensionAttribute.cs │ │ ├── SqlTestHelpers.cs │ │ ├── SqlTestResult.cs │ │ ├── SupportedServerVersionRange.cs │ │ ├── SupportedTargetServerFriendlyName.cs │ │ ├── TestDescriptor.cs │ │ ├── TestServerDescriptor.cs │ │ ├── TestServerPoolManager.cs │ │ ├── UnsupportedDatabaseEngineEditionAttribute.cs │ │ ├── UnsupportedDatabaseEngineTypeAttribute.cs │ │ ├── UnsupportedFeatureAttribute.cs │ │ └── UnsupportedHostPlatformAttribute.cs │ ├── azuresql.runsettings │ ├── azuresqldwgen3.runsettings │ ├── azuresqledge.runsettings │ ├── azuresqlnodrop.runsettings │ ├── fabricnative.runsettings │ ├── functionaltest.runsettings │ ├── linux.runsettings │ ├── ondemand.runsettings │ ├── onprem.runsettings │ ├── sql2008.runsettings │ ├── sql2012.runsettings │ ├── sql2014.runsettings │ ├── sql2016.runsettings │ ├── sql2017.runsettings │ ├── sqlexpress.runsettings │ ├── sqlmi.runsettings │ ├── sqlmiarc.runsettings │ ├── sqlv150.runsettings │ ├── sqlv160.runsettings │ └── sqlv170.runsettings ├── Identity │ ├── AdoOidcResponse.cs │ ├── AzureDevOpsFederatedTokenCredential.cs │ ├── AzureDevOpsFederatedTokenCredentialOptions.cs │ ├── AzureDevOpsSqlAuthenticationProvider.cs │ ├── Microsoft.SqlServer.ADO.Identity.csproj │ └── README.md ├── Smo │ ├── Agent │ │ ├── JobFilterTests.cs │ │ └── JobServerTests.cs │ ├── BackupRestore │ │ ├── BackupRestoreTests.cs │ │ ├── LongFullBackupCleanup.sql │ │ ├── LongFullBackupPlan.sql │ │ ├── LongFullBackupSetup.sql │ │ ├── NewerOutOfSequenceCleanup.sql │ │ ├── NewerOutOfSequencePointInTimePlan.sql │ │ ├── NewerOutOfSequenceSetup.sql │ │ ├── OlderOutOfSequenceCleanup.sql │ │ ├── OlderOutOfSequencePointInTimePlan.sql │ │ └── OlderOutOfSequenceSetup.sql │ ├── CentralManagementServer │ │ ├── CmsTests.cs │ │ └── TestSrvr.xml │ ├── DMF │ │ ├── ExecutionHistoryTests.cs │ │ ├── PolicyTests.cs │ │ └── SfcXmlHelper.cs │ ├── GeneralFunctionality │ │ ├── AuditSmoTests.cs │ │ ├── DataClassificationSmoTests.cs │ │ ├── DatabaseSmoTests.cs │ │ ├── DifferencingTests.cs │ │ ├── DiskFile.cs │ │ ├── DwSmoTests.cs │ │ ├── PermissionsEnumTests.cs │ │ ├── ServerConnectionTests.cs │ │ ├── ServerSmoTests.cs │ │ ├── SmoInitializingTests.cs │ │ └── SmoTestsUtility.cs │ ├── MetadataProvider │ │ └── MetadataProviderTests.cs │ ├── Microsoft.SqlServer.Test.Smo.csproj │ ├── README.md │ ├── ScriptingTests │ │ ├── Alert_SmoTestSuite.cs │ │ ├── ApplicationRole_SmoTestSuite.cs │ │ ├── Audit_SmoTestSuite.cs │ │ ├── AvailabilityGroupListener_SmoTestSuite.cs │ │ ├── AvailabilityGroup_SmoTestSuite.cs │ │ ├── BackupDevice_SmoTestSuite.cs │ │ ├── Backup_SmoTestSuite.cs │ │ ├── BrokerPriority_SmoTestSuite.cs │ │ ├── BrokerService_SmoTestSuite.cs │ │ ├── Category_SmoTestSuite.cs │ │ ├── Certificate_SmoTestSuite.cs │ │ ├── Check_SmoTestSuite.cs │ │ ├── ColumnEncryptionKeyValue_SmoTestSuite.cs │ │ ├── ColumnEncryptionKey_SmoTestSuite.cs │ │ ├── ColumnMasterKey_SmoTestSuite.cs │ │ ├── Column_SmoTestSuite.cs │ │ ├── Credential_SmoTestSuite.cs │ │ ├── CryptographicProvider_SmoTestSuite.cs │ │ ├── Data │ │ │ └── qatest │ │ │ │ └── bands.dat │ │ ├── DatabaseAuditSpecification_SmoTestSuite.cs │ │ ├── DatabaseDdlTrigger_SmoTestSuite.cs │ │ ├── DatabaseEncryptionKey_SmoTestSuite.cs │ │ ├── DatabaseOptions_SmoTestSuite.cs │ │ ├── DatabaseRole_SmoTestSuite.cs │ │ ├── DatabaseScopedCredential_SmoTestSuite.cs │ │ ├── Database_SmoTestSuite.cs │ │ ├── DefaultConstraint_SmoTestSuite.cs │ │ ├── DefaultRule_SmoTestSuite.cs │ │ ├── EdgeConstraint_SmoTestSuite.cs │ │ ├── Endpoint_SmoTestSuite.cs │ │ ├── ExtendedProperty_SmoTestSuite.cs │ │ ├── ExternalDataSource_SmoTestSuite.cs │ │ ├── ExternalFileFormat_SmoTestSuite.cs │ │ ├── ExternalLanguage_SmoTestSuite.cs │ │ ├── ExternalLibrary_SmoTestSuite.cs │ │ ├── ExternalResourcePool_SmoTestSuite.cs │ │ ├── ExternalStream_SmoTestSuite.cs │ │ ├── ExternalStreamingJob_SmoTestSuite.cs │ │ ├── File_SmoTestSuite.cs │ │ ├── ForeignKey_SmoTestSuite.cs │ │ ├── FullTextCatalog_SmoTestSuite.cs │ │ ├── FullTextIndex_SmoTestSuite.cs │ │ ├── FullTextStopList_SmoTestSuite.cs │ │ ├── Index_SmoTestSuite.cs │ │ ├── JobSchedule_SmoTestSuite.cs │ │ ├── JobStep_SmoTestSuite.cs │ │ ├── Job_SmoTestSuite.cs │ │ ├── LinkedServerLogin_SmoTestSuite.cs │ │ ├── LinkedServer_SmoTestSuite.cs │ │ ├── Login_SmoTestSuite.cs │ │ ├── MailAccount_SmoTestSuite.cs │ │ ├── MailProfile_SmoTestSuite.cs │ │ ├── MessageType_SmoTestSuite.cs │ │ ├── Operator_SmoTestSute.cs │ │ ├── PartitionFunction_SmoTestSuite.cs │ │ ├── PartitionScheme_SmoTestSuite.cs │ │ ├── PhysicalPartition_SmoTestSuite.cs │ │ ├── PlanGuide_SmoTestSuite.cs │ │ ├── ProxyAccount_SmoTestSuite.cs │ │ ├── QueryStore_SmoTestSuite.cs │ │ ├── RegressionTests.cs │ │ ├── RemoteServiceBinding_SmoTestSuite.cs │ │ ├── ResourcePool_SmoTestSuite.cs │ │ ├── Restore_SmoTestSuite.cs │ │ ├── Schema_SmoTestSuite.cs │ │ ├── ScriptMakerTests.cs │ │ ├── ScripterTests.cs │ │ ├── ScriptingTestSuite.cs │ │ ├── Scripts │ │ │ ├── DatabaseEncryptionKey_SmoTestSuite_SQL2016_Setup.sql │ │ │ ├── DependencyOrderScriptingDb.sql │ │ │ ├── ExternalLibrary_SmoTestSuite_Setup.sql │ │ │ ├── PartitionedTable.sql │ │ │ └── SqlAssembly_SmoTestSuite_SQL2016_Setup.sql │ │ ├── SearchPropertyList_SmoTestSuite.cs │ │ ├── SecurityPolicy_SmoTestSuite.cs │ │ ├── SecurityPredicate_SmoTestSuite.cs │ │ ├── SensitivityClassification_SmoTestSuite.cs │ │ ├── Sequence_SmoTestSuite.cs │ │ ├── ServerAuditSpecification_SmoTestSuite.cs │ │ ├── ServerDdlTrigger_SmoTestSuite.cs │ │ ├── ServerRole_SmoTestSuite.cs │ │ ├── Server_SmoTestSuite.cs │ │ ├── ServiceContract_SmoTestSuite.cs │ │ ├── ServiceQueue_SmoTestSuite.cs │ │ ├── ServiceRoute_SmoTestSuite.cs │ │ ├── SmoTestFramework │ │ │ └── SmoTestBase.cs │ │ ├── SqlAssembly_SmoTestSuite.cs │ │ ├── Statistic_SmoTestSuite.cs │ │ ├── StoredProcedure_SmoTestSuite.cs │ │ ├── Synonym_SmoTestSuite.cs │ │ ├── Table_SmoTestSuite.cs │ │ ├── TargetServerGroup_SmoTestSuite.cs │ │ ├── TestHelpers │ │ │ ├── AlwaysOnTestHelper.cs │ │ │ └── SmoObjectTestBase.cs │ │ ├── Trigger_SmoTestSuite.cs │ │ ├── UserDefinedAggregate_SmoTestSuite.cs │ │ ├── UserDefinedDataType_SmoTestSuite.cs │ │ ├── UserDefinedFunction_SmoTestSuite.cs │ │ ├── UserDefinedTableType_SmoTestSuite.cs │ │ ├── UserDefinedType_SmoTestSuite.cs │ │ ├── User_SmoTestSuite.cs │ │ ├── ValidateTableDataRetention_DataRetentionPeriodOption.sql │ │ ├── View_SmoTestSuite.cs │ │ ├── WorkloadGroup_SmoTestSuite.cs │ │ ├── WorkloadManagementWorkloadClassifier_SmoTestSuite.cs │ │ ├── WorkloadManagementWorkloadGroup_SmoTestSuite.cs │ │ └── XmlSchemaCollection_SmoTestSuite.cs │ ├── Sfc │ │ ├── AlienTests.cs │ │ └── SfcEnumeratorTests.cs │ ├── SqlAssessment │ │ └── SqlAssessmentTests.cs │ ├── ToolsConnectionInfo.xml │ ├── WMI │ │ └── ServerEventsTests.cs │ └── XEvent │ │ ├── ActionInfoUnitTest.cs │ │ ├── ActionUnitTest.cs │ │ ├── DataEventColumnInfoUnitTest.cs │ │ ├── DbScopedXEventTestBase.cs │ │ ├── EnumeratorUnitTest.cs │ │ ├── EventColumnInfoUnitTest.cs │ │ ├── EventFieldUnitTest.cs │ │ ├── EventInfoUnitTest.cs │ │ ├── EventUnitTest.cs │ │ ├── MapInfoUnitTest.cs │ │ ├── MapValueInfoUnitTest.cs │ │ ├── PackageUnitTest.cs │ │ ├── PredCompareExprUnitTest.cs │ │ ├── PredCompareUnitTest.cs │ │ ├── PredFunctionExprUnitTest.cs │ │ ├── PredLogicalExprUnitTest.cs │ │ ├── PredOperandUnitTest.cs │ │ ├── PredSourceInfoUnitTest.cs │ │ ├── PredValueUnitTest.cs │ │ ├── ReadOnlyEventColumnInfoUnitTest.cs │ │ ├── SessionUnitTest.cs │ │ ├── TargetColumnInfoUnitTest.cs │ │ ├── TargetFieldUnitTest.cs │ │ ├── TargetInfoUnitTest.cs │ │ ├── TargetUnitTest.cs │ │ ├── TypeInfoUnitTest.cs │ │ ├── Util.cs │ │ ├── XEStoreUnitTest.cs │ │ └── XEventSessionTests.cs └── dirs.proj ├── Microsoft ├── Data │ └── Tools.Sql.BatchParser │ │ ├── BatchParser.cs │ │ ├── BatchParserAction.cs │ │ ├── BatchParserException.cs │ │ ├── ErrorCode.cs │ │ ├── ICommandHandler.cs │ │ ├── IVariableResolver.cs │ │ ├── Lexer.cs │ │ ├── LexerInput.cs │ │ ├── LexerTokenType.cs │ │ ├── LineInfo.cs │ │ ├── Microsoft.Data.Tools.Sql.BatchParser.csproj │ │ ├── OnErrorAction.cs │ │ ├── Parser.cs │ │ ├── PositionStruct.cs │ │ ├── TextBlock.cs │ │ ├── TextRuleFlags.cs │ │ ├── Token.cs │ │ ├── VariableReference.cs │ │ └── sr.strings ├── Directory.Build.props ├── Directory.Build.targets ├── SqlServer │ ├── Management │ │ ├── ConnectionInfo │ │ │ ├── App.config │ │ │ ├── AssemblyInfo.cs │ │ │ ├── ConnectionEnums.cs │ │ │ ├── ConnectionException.cs │ │ │ ├── ConnectionInfoBase.cs │ │ │ ├── ConnectionInfoHelper.cs │ │ │ ├── ConnectionManager.cs │ │ │ ├── ConnectionSettings.cs │ │ │ ├── DatabaseEngineTypeExtensionClass.cs │ │ │ ├── DtsConnectionInfo.cs │ │ │ ├── EncryptionUtility.cs │ │ │ ├── ExecutionCache.cs │ │ │ ├── FxCopSupressions.cs │ │ │ ├── IRenewableToken.cs │ │ │ ├── ISfcConnection.cs │ │ │ ├── LocalizableTypeConverter.cs │ │ │ ├── Microsoft.SqlServer.ConnectionInfo.csproj │ │ │ ├── NetCoreHelpers.cs │ │ │ ├── OlapConnectionInfo.cs │ │ │ ├── ServerConnection.cs │ │ │ ├── ServerInformation.cs │ │ │ ├── ServerVersion.cs │ │ │ ├── SqlCeConnectionInfo.cs │ │ │ ├── SqlConnectionInfo.cs │ │ │ ├── SqlConnectionInfoWithConnection.cs │ │ │ ├── SqlContext.cs │ │ │ ├── SqlDirectConnection.cs │ │ │ ├── SqlOlapConnectionInfoBase.cs │ │ │ ├── SqlServerManagementException.cs │ │ │ ├── StatementCapture.cs │ │ │ ├── StatementEvent.cs │ │ │ ├── StringConnectionInfo.strings │ │ │ ├── WindowsCredential.cs │ │ │ ├── WmiMgmtScopeConnection.cs │ │ │ ├── interfaces.cs │ │ │ └── safenativemethods.cs │ │ ├── Dmf.Common │ │ │ ├── AssemblyInfo.cs │ │ │ ├── CustomAttributes.cs │ │ │ ├── DmfConstants.cs │ │ │ ├── DmfException.cs │ │ │ ├── ExceptionTemplates.strings │ │ │ ├── FxCopExclusions.cs │ │ │ ├── ManagementFacet.cs │ │ │ ├── Microsoft.SqlServer.Dmf.Common.csproj │ │ │ ├── NetCoreHelpers.cs │ │ │ ├── PostConfigurationActionAttribute.cs │ │ │ ├── Utils.cs │ │ │ └── enumstructs.cs │ │ ├── Dmf │ │ │ ├── AssemblyInfo.cs │ │ │ ├── Condition.cs │ │ │ ├── ConditionCollection.cs │ │ │ ├── ConditionExtender.cs │ │ │ ├── ConditionValidation.cs │ │ │ ├── ConnectionEvaluationHistory.cs │ │ │ ├── ConnectionEvaluationHistoryCollection.cs │ │ │ ├── EvaluationDetail.cs │ │ │ ├── EvaluationDetailCollection.cs │ │ │ ├── EvaluationFactory.cs │ │ │ ├── EvaluationHistory.cs │ │ │ ├── EvaluationHistoryCollection.cs │ │ │ ├── ExceptionTemplates.strings │ │ │ ├── ExpressionTree.cs │ │ │ ├── FacetInfo.cs │ │ │ ├── FacetInfoCollection.cs │ │ │ ├── FacetProperties.strings │ │ │ ├── FacetRepository.cs │ │ │ ├── FxCopExclusions.cs │ │ │ ├── LocalizableResources.strings │ │ │ ├── Microsoft.SqlServer.Dmf.csproj │ │ │ ├── ObjectSet.cs │ │ │ ├── ObjectSetCollection.cs │ │ │ ├── ObjectSetValidation.cs │ │ │ ├── Policy.cs │ │ │ ├── PolicyCategory.cs │ │ │ ├── PolicyCategoryCollection.cs │ │ │ ├── PolicyCategoryInformation.cs │ │ │ ├── PolicyCategorySubscription.cs │ │ │ ├── PolicyCategorySubscriptionCollection.cs │ │ │ ├── PolicyCategorySubscriptionValidation.cs │ │ │ ├── PolicyCollection.cs │ │ │ ├── PolicyEvaluationResultsWriter.cs │ │ │ ├── PolicyEvents.cs │ │ │ ├── PolicyExtender.cs │ │ │ ├── PolicyStore.cs │ │ │ ├── PolicyStoreValidation.cs │ │ │ ├── PolicyValidation.cs │ │ │ ├── TargetSet.cs │ │ │ ├── TargetSetCollection.cs │ │ │ ├── TargetSetLevel.cs │ │ │ ├── TargetSetLevelCollection.cs │ │ │ └── Utils.cs │ │ ├── HadrData │ │ │ ├── AGListenerNetworkMode.cs │ │ │ ├── AvailabilityGroupData.cs │ │ │ ├── AvailabilityGroupListenerConfiguration.cs │ │ │ ├── AvailabilityGroupListenerSubnet.cs │ │ │ ├── AvailabilityGroupReplica.cs │ │ │ ├── AvailabilityGroupReplicaCollection.cs │ │ │ ├── AvailabilityGroupReplicaData.cs │ │ │ ├── AvailabilityObjectState.cs │ │ │ ├── CollectionsExtensionMethods.cs │ │ │ ├── Constants.cs │ │ │ ├── DataSynchronizationOption.cs │ │ │ ├── FailoverCategory.cs │ │ │ ├── FailoverData.cs │ │ │ ├── FailoverUtilities.cs │ │ │ ├── Microsoft.SqlServer.Management.HadrData.csproj │ │ │ ├── PrimaryDatabaseData.cs │ │ │ ├── Properties │ │ │ │ └── AssemblyInfo.cs │ │ │ ├── ReplicaRole.cs │ │ │ ├── Resource.Designer.cs │ │ │ ├── Resource.resx │ │ │ ├── SortableBindingList.cs │ │ │ └── UserSecurity.cs │ │ ├── HadrModel │ │ │ ├── AddDBCredentialTask.cs │ │ │ ├── AddDatabaseToExistingAGScenarioProvider.cs │ │ │ ├── AddDatabaseToExistingAvailabilityGroupTask.cs │ │ │ ├── AddNewAvailabilityGroupListenerTask.cs │ │ │ ├── AddReplicaDatabaseExistenceValidator.cs │ │ │ ├── AddReplicaDatabaseFileCompatibilityValidator.cs │ │ │ ├── AddReplicaDatabaseFileExistenceValidator.cs │ │ │ ├── AddReplicaTask.cs │ │ │ ├── AddReplicasToExistingAvailabilityGroupScenarioProvider.cs │ │ │ ├── AvailabilityGroupNotJoinedOnReplicaException.cs │ │ │ ├── AvailabilityGroupQuorumValidationTask.cs │ │ │ ├── AvailabilityGroupQuorumValidationTaskException.cs │ │ │ ├── AvailabilityModeIncompatibleException.cs │ │ │ ├── AvailabilityModeValidator.cs │ │ │ ├── BackupDatabaseTask.cs │ │ │ ├── BackupDatabaseTaskException.cs │ │ │ ├── BackupLocationValidator.cs │ │ │ ├── BackupLogTask.cs │ │ │ ├── BackupLogTaskException.cs │ │ │ ├── BasicAvailabilityGroupIncompatibleException.cs │ │ │ ├── BasicAvailabilityGroupValidator.cs │ │ │ ├── ClusterNodeState.cs │ │ │ ├── CompatibleEncryptionValidator.cs │ │ │ ├── ConfigureEndpointsTask.cs │ │ │ ├── CreateAvailabilityGroupDatabaseExistenceValidator.cs │ │ │ ├── CreateAvailabilityGroupDatabaseFileCompatibilityValidator.cs │ │ │ ├── CreateAvailabilityGroupDatabaseFileExistenceValidator.cs │ │ │ ├── CreateAvailabilityGroupListenerTask.cs │ │ │ ├── CreateAvailabilityGroupScenarioProvider.cs │ │ │ ├── CreateAvailabilityGroupTask.cs │ │ │ ├── CreateLoginTask.cs │ │ │ ├── DBMasterKeyValidator.cs │ │ │ ├── DatabaseAlreadyExistsException.cs │ │ │ ├── DatabaseExistenceValidator.cs │ │ │ ├── DatabaseFileAlreadyExistsOnReplicaException.cs │ │ │ ├── DatabaseFileCompatibilityValidator.cs │ │ │ ├── DatabaseFileExistenceValidator.cs │ │ │ ├── DatabaseFileLocationMissingOnReplicaException.cs │ │ │ ├── DatabaseFileNotInDefaultDirectoryException.cs │ │ │ ├── DriveNotFoundOnReplicaException.cs │ │ │ ├── EditExistingAvailabilityGroupListenerTask.cs │ │ │ ├── EncryptionAlgorithmMismatchException.cs │ │ │ ├── EncryptionMismatchException.cs │ │ │ ├── EndpointAuthenticationValidationException.cs │ │ │ ├── EndpointAuthenticationValidator.cs │ │ │ ├── FailoverQuorumVoteConfigurationValidator.cs │ │ │ ├── FailoverScenarioProvider.cs │ │ │ ├── FailoverTask.cs │ │ │ ├── FailoverValidationException.cs │ │ │ ├── FailoverValidator.cs │ │ │ ├── FailoverWaitRoleChangeTask.cs │ │ │ ├── FeatureInstallationState.cs │ │ │ ├── FixedRetryCountPolicy.cs │ │ │ ├── FixedTimeoutRetryPolicy.cs │ │ │ ├── FreeDiskSpaceValidator.cs │ │ │ ├── GroupUserMembership.cs │ │ │ ├── HADRValidationBaseException.cs │ │ │ ├── HadrModelUtilities.cs │ │ │ ├── HadrTaskBaseException.cs │ │ │ ├── HadrTaskErrorException.cs │ │ │ ├── HadrValidationErrorException.cs │ │ │ ├── HadrValidationWarningException.cs │ │ │ ├── IExecutionPolicy.cs │ │ │ ├── IScriptableTask.cs │ │ │ ├── ITasksProvider.cs │ │ │ ├── IValidatorProvider.cs │ │ │ ├── InSufficientFreeSpaceForDatabaseFilesException.cs │ │ │ ├── InvalidAvailabilityGroupException.cs │ │ │ ├── JoinDatabaseToAvailabilityGroupException.cs │ │ │ ├── JoinDatabaseToAvailabilityGroupTask.cs │ │ │ ├── JoinSecondariesTask.cs │ │ │ ├── ListenerConfigurationException.cs │ │ │ ├── ListenerConfigurationValidator.cs │ │ │ ├── MaxHostedServicesException.cs │ │ │ ├── Microsoft.SqlServer.Management.HadrModel.csproj │ │ │ ├── ModelDelegates.cs │ │ │ ├── PercentCompleteHandler.cs │ │ │ ├── PrimaryCannotWriteToLocationException.cs │ │ │ ├── Properties │ │ │ │ └── AssemblyInfo.cs │ │ │ ├── QuorumHelper.cs │ │ │ ├── QuorumHelperException.cs │ │ │ ├── Resource.Designer.cs │ │ │ ├── Resource.resx │ │ │ ├── RestartSqlServerException.cs │ │ │ ├── RestoreDatabaseTask.cs │ │ │ ├── RestoreDatabaseTaskException.cs │ │ │ ├── RestoreLogTask.cs │ │ │ ├── RestoreLogTaskException.cs │ │ │ ├── RunOncePolicy.cs │ │ │ ├── ScenarioProvider.cs │ │ │ ├── SecondaryCannotReadLocationException.cs │ │ │ ├── ServiceOperationStatusException.cs │ │ │ ├── ShareValidationException.cs │ │ │ ├── SqlServerConnectionException.cs │ │ │ ├── StartAlwaysOnXeventSessionTask.cs │ │ │ ├── StringExtensionMethods.cs │ │ │ ├── Task.cs │ │ │ ├── TaskEventArgs.cs │ │ │ ├── TaskEventStatus.cs │ │ │ ├── UpdateAvailabilityGroupListenerTask.cs │ │ │ ├── Validator.cs │ │ │ ├── ValidatorEventArgs.cs │ │ │ └── WaitForAvailabilityGroupOnlineTask.cs │ │ ├── PolicyEnum │ │ │ ├── FxCopExclusions.cs │ │ │ ├── Microsoft.SqlServer.PolicyEnum.csproj │ │ │ ├── PolicyEnum.cs │ │ │ ├── PolicyObject.cs │ │ │ └── xml │ │ │ │ ├── Condition.xml │ │ │ │ ├── ConnectionEvaluationHistory.xml │ │ │ │ ├── EvaluationDetail.xml │ │ │ │ ├── EvaluationHistory.xml │ │ │ │ ├── ObjectSet.xml │ │ │ │ ├── Policy.xml │ │ │ │ ├── PolicyCategory.xml │ │ │ │ ├── PolicyCategorySubscription.xml │ │ │ │ ├── PolicyStore.xml │ │ │ │ ├── TargetFilter.xml │ │ │ │ ├── TargetSet.xml │ │ │ │ ├── TargetSetLevel.xml │ │ │ │ ├── inc_urn.xml │ │ │ │ └── inc_urnByID.xml │ │ ├── RegisteredServers │ │ │ ├── AzureDataStudioConnection.cs │ │ │ ├── AzureDataStudioConnectionStore.cs │ │ │ ├── AzureStudioConnectionGroup.cs │ │ │ ├── Microsoft.SqlServer.Management.RegisteredServers.csproj │ │ │ ├── RegSvrStrings.strings │ │ │ ├── RegisteredServer.cs │ │ │ ├── RegisteredServerCollection.cs │ │ │ ├── RegisteredServerException.cs │ │ │ ├── RegisteredServersEnumerator.cs │ │ │ ├── RegisteredServersStore.cs │ │ │ ├── ServerGroup.cs │ │ │ ├── ServerGroupCollection.cs │ │ │ └── xml │ │ │ │ ├── RegisteredServer.xml │ │ │ │ ├── RegisteredServersStore.xml │ │ │ │ ├── ServerGroup.xml │ │ │ │ └── inc_urn.xml │ │ ├── Sdk │ │ │ └── Sfc │ │ │ │ ├── AlienSupport.cs │ │ │ │ ├── AssemblyInfo.cs │ │ │ │ ├── CollectionInfo.cs │ │ │ │ ├── CrudInterfaces.cs │ │ │ │ ├── Differencing │ │ │ │ ├── API │ │ │ │ │ ├── DifferencingService.cs │ │ │ │ │ ├── IDifferencer.cs │ │ │ │ │ └── IDiffgram.cs │ │ │ │ ├── Differencing.vsmdi │ │ │ │ ├── Impl │ │ │ │ │ ├── Differencer.cs │ │ │ │ │ └── Diffgram.cs │ │ │ │ ├── LocalTestRun.testrunconfig │ │ │ │ ├── SPI │ │ │ │ │ ├── MetadataNodeItemNamesProvider.cs │ │ │ │ │ ├── ProviderRegistry.cs │ │ │ │ │ └── Providers.cs │ │ │ │ └── StringDifferencing.strings │ │ │ │ ├── Enumerator │ │ │ │ ├── AstNode.cs │ │ │ │ ├── Axis.cs │ │ │ │ ├── ConditionedSql.cs │ │ │ │ ├── DataProvider.cs │ │ │ │ ├── Depedencies.cs │ │ │ │ ├── EnumObject.CS │ │ │ │ ├── EnumeratorException.CS │ │ │ │ ├── Enviroment.CS │ │ │ │ ├── Filter.cs │ │ │ │ ├── FilterNode.cs │ │ │ │ ├── FilterTranslate.cs │ │ │ │ ├── Function.cs │ │ │ │ ├── FxCopExclusions.cs │ │ │ │ ├── Group.cs │ │ │ │ ├── ObjectCache.cs │ │ │ │ ├── ObjectInfo.cs │ │ │ │ ├── ObjectLoadInfoManager.cs │ │ │ │ ├── ObjectProperty.cs │ │ │ │ ├── Operand.cs │ │ │ │ ├── Operator.cs │ │ │ │ ├── PostProcess.cs │ │ │ │ ├── RequestDependencies.cs │ │ │ │ ├── RequestObjectInfo.cs │ │ │ │ ├── RequestParentSelect.cs │ │ │ │ ├── Root.cs │ │ │ │ ├── SqlConditionedStatement.cs │ │ │ │ ├── SqlLinkMultiple.cs │ │ │ │ ├── SqlObject.cs │ │ │ │ ├── SqlObjectBase.cs │ │ │ │ ├── SqlObjectProperty.cs │ │ │ │ ├── SqlParentLink.cs │ │ │ │ ├── SqlPostProcess.cs │ │ │ │ ├── SqlPropertyLink.cs │ │ │ │ ├── SqlRequest.cs │ │ │ │ ├── Util.cs │ │ │ │ ├── XPathException.cs │ │ │ │ ├── XPathExpresionBlock.cs │ │ │ │ ├── XPathHandler.cs │ │ │ │ ├── XPathNodeType.cs │ │ │ │ ├── XPathScanner.cs │ │ │ │ ├── XmlCharType.cs │ │ │ │ ├── XmlRead.cs │ │ │ │ ├── XmlUtil.CS │ │ │ │ ├── enumerator.cs │ │ │ │ ├── enumresult.cs │ │ │ │ ├── executesql.cs │ │ │ │ ├── filterdecoder.cs │ │ │ │ ├── interfaces.cs │ │ │ │ ├── request.cs │ │ │ │ ├── sqlenumresult.cs │ │ │ │ ├── statementbuilder.cs │ │ │ │ ├── urn.cs │ │ │ │ ├── xml │ │ │ │ │ └── Config.xml │ │ │ │ └── xpathexpresion.cs │ │ │ │ ├── Exception.cs │ │ │ │ ├── FxCopExclusions.cs │ │ │ │ ├── ISfcDomain.cs │ │ │ │ ├── ISfcExecutionEngine.cs │ │ │ │ ├── ISfcNotifyPropertyChanged.cs │ │ │ │ ├── ISfcProperty.cs │ │ │ │ ├── ISfcPropertyProvider.cs │ │ │ │ ├── ISfcPropertySet.cs │ │ │ │ ├── ISfcScriptCollector.cs │ │ │ │ ├── ISfcSimpleNode.cs │ │ │ │ ├── ISfcStorageProvider.cs │ │ │ │ ├── ISfcSupportsDesignMode.cs │ │ │ │ ├── ISfcscript.cs │ │ │ │ ├── LocalizableTypeConverter.cs │ │ │ │ ├── Microsoft.SqlServer.Management.Sdk.Sfc.csproj │ │ │ │ ├── NetCoreExtension.cs │ │ │ │ ├── NonSfcObjectIterator.cs │ │ │ │ ├── ReadOnlyDictionary.cs │ │ │ │ ├── ReadOnlyList.cs │ │ │ │ ├── ReadonlyInterfaces.cs │ │ │ │ ├── SQLToolsOutputDebugStringListener.cs │ │ │ │ ├── SQLToolsTraceListenerCollection.cs │ │ │ │ ├── Serializer.cs │ │ │ │ ├── SfcApplication.cs │ │ │ │ ├── SfcAttributes.cs │ │ │ │ ├── SfcCache.cs │ │ │ │ ├── SfcCollatedDictionaryBase.cs │ │ │ │ ├── SfcCollection.cs │ │ │ │ ├── SfcConnection.cs │ │ │ │ ├── SfcDependency.cs │ │ │ │ ├── SfcDictionaryBase.cs │ │ │ │ ├── SfcExecutionEngine.cs │ │ │ │ ├── SfcInstance.cs │ │ │ │ ├── SfcKey.cs │ │ │ │ ├── SfcListBase.cs │ │ │ │ ├── SfcMetadata.cs │ │ │ │ ├── SfcMetadataException.cs │ │ │ │ ├── SfcObjectExtender.cs │ │ │ │ ├── SfcObjectFactory.cs │ │ │ │ ├── SfcObjectIterator.cs │ │ │ │ ├── SfcObjectQuery.cs │ │ │ │ ├── SfcPath.cs │ │ │ │ ├── SfcProperty.cs │ │ │ │ ├── SfcQueryExpression.cs │ │ │ │ ├── SfcReferenceCollection.cs │ │ │ │ ├── SfcRegistration.cs │ │ │ │ ├── SfcSerializationAdapter.cs │ │ │ │ ├── SfcSerializerUpgrade.cs │ │ │ │ ├── SfcSimpleNode.cs │ │ │ │ ├── SfcSimpleNodeAdapter.cs │ │ │ │ ├── SfcStrings.strings │ │ │ │ ├── SfcTsqlProcFormatter.cs │ │ │ │ ├── SfcValidation.cs │ │ │ │ ├── SmoManagementUtil.cs │ │ │ │ ├── SqlStoreConnection.cs │ │ │ │ ├── TraceHelper.cs │ │ │ │ ├── TypeMetadata.cs │ │ │ │ ├── Util.cs │ │ │ │ ├── XmlTextReader.cs │ │ │ │ ├── connectionhelpers.cs │ │ │ │ └── dmf.cs │ │ ├── Smo.Broker │ │ │ ├── AssemblyInfo.cs │ │ │ ├── FxCopExclusions.cs │ │ │ ├── Microsoft.SqlServer.ServiceBrokerEnum.csproj │ │ │ ├── ServiceBrokerEnum.cs │ │ │ ├── ServiceBrokerSqlObject.cs │ │ │ └── xml │ │ │ │ ├── BrokerPriority.xml │ │ │ │ ├── BrokerService.xml │ │ │ │ ├── MessageType.xml │ │ │ │ ├── MessageTypeMapping.xml │ │ │ │ ├── RemoteServiceBinding.xml │ │ │ │ ├── ServiceBroker.xml │ │ │ │ ├── ServiceContract.xml │ │ │ │ ├── ServiceContractMapping.xml │ │ │ │ ├── ServiceQueues.xml │ │ │ │ ├── ServiceRoute.xml │ │ │ │ ├── inc_ext_prop.xml │ │ │ │ ├── inc_policy_health_state.xml │ │ │ │ ├── inc_urn.xml │ │ │ │ └── inc_urn_schema.xml │ │ ├── Smo.Extended │ │ │ ├── Backup.cs │ │ │ ├── BackupEncryptionOptions.cs │ │ │ ├── BackupRestoreBase.cs │ │ │ ├── DataTransferBase.cs │ │ │ ├── DatabaseRestorePlanner.cs │ │ │ ├── DatabaseRestorePlannerSR.strings │ │ │ ├── DependencyObject.cs │ │ │ ├── Microsoft.SqlServer.SmoExtended.csproj │ │ │ ├── NetCoreHelpers.cs │ │ │ ├── PageRestorePlanner.cs │ │ │ ├── Prefetch.cs │ │ │ ├── Restore.cs │ │ │ ├── RestoreOptions.cs │ │ │ ├── RestorePlan.cs │ │ │ ├── Transfer.cs │ │ │ ├── TransferBase.cs │ │ │ ├── TransferInterfaces.cs │ │ │ └── TransferWriter.cs │ │ ├── Smo.Notebook │ │ │ ├── CellModel.cs │ │ │ ├── CodeCellModel.cs │ │ │ ├── MarkdownCellModel.cs │ │ │ ├── Microsoft.SqlServer.Smo.Notebook.csproj │ │ │ ├── NotebookFileWriter.cs │ │ │ ├── NotebookModel.cs │ │ │ └── SmoNotebook.cs │ │ ├── Smo.RegSvrEnum │ │ │ ├── Crypto.cs │ │ │ ├── Delegates.cs │ │ │ ├── EnumRegisteredServer.cs │ │ │ ├── FxCopExclusions.cs │ │ │ ├── GroupRegistrationInfo.cs │ │ │ ├── Microsoft.SqlServer.RegSvrEnum.csproj │ │ │ ├── ParentRegistrationInfo.cs │ │ │ ├── RegServersException.cs │ │ │ ├── RegistrationInfo.cs │ │ │ ├── RegistrationInfoCollection.cs │ │ │ ├── RegistrationProvider.cs │ │ │ ├── SRError.strings │ │ │ ├── ServerInstanceRegistrationInfo.cs │ │ │ ├── ServerTypeRegistrationInfo.cs │ │ │ ├── Tracing.cs │ │ │ ├── UIConnectionGroupInfo.cs │ │ │ ├── UIConnectionInfo.cs │ │ │ └── Utils.cs │ │ ├── Smo.Wmi │ │ │ ├── ClientProtocol.cs │ │ │ ├── ClientProtocolBase.cs │ │ │ ├── Collections │ │ │ │ ├── ClientProtocolCollection.cs │ │ │ │ ├── ServerIPAddressCollection.cs │ │ │ │ ├── ServerInstanceCollection.cs │ │ │ │ ├── ServerProtocolCollection.cs │ │ │ │ ├── ServiceAliasCollection.cs │ │ │ │ └── ServiceCollection.cs │ │ │ ├── ManagedComputer.cs │ │ │ ├── Microsoft.SqlServer.SqlWmiManagement.csproj │ │ │ ├── ProtocolBase.cs │ │ │ ├── ProtocolPropertyCollection.cs │ │ │ ├── ServerAlias.cs │ │ │ ├── ServerAliasBase.cs │ │ │ ├── ServerIPAddress.cs │ │ │ ├── ServerIPAddressBase.cs │ │ │ ├── ServerInstance.cs │ │ │ ├── ServerInstanceBase.cs │ │ │ ├── ServerProtocol.cs │ │ │ ├── ServerProtocolBase.cs │ │ │ ├── Service.cs │ │ │ ├── ServiceBase.cs │ │ │ ├── WmiCollectionBase.cs │ │ │ ├── WmiCollectionTemplate.cs │ │ │ ├── WmiMgmt.strings │ │ │ ├── WmiSmoObject.cs │ │ │ └── coll_macros.h │ │ ├── Smo.WmiEnum │ │ │ ├── CNetLibInfo.cs │ │ │ ├── ClientProtocol.cs │ │ │ ├── ClientProtocolProperties.cs │ │ │ ├── FxCopExclusions.cs │ │ │ ├── ManagedComputer.cs │ │ │ ├── Microsoft.SqlServer.WmiEnum.csproj │ │ │ ├── ProtocolPropertiesBase.cs │ │ │ ├── SAlias.cs │ │ │ ├── ServerInstance.cs │ │ │ ├── ServerProtocol.cs │ │ │ ├── ServerProtocolIPAddress.cs │ │ │ ├── ServerProtocolIPAddressProperty.cs │ │ │ ├── ServerProtocolProperties.cs │ │ │ ├── Service.cs │ │ │ ├── ServiceAdvancedProperty.cs │ │ │ ├── StringWmiEnumerator.strings │ │ │ ├── WmiBase.cs │ │ │ ├── WmiEnum.cs │ │ │ ├── WmiProperty.cs │ │ │ ├── wmienumresult.cs │ │ │ └── wmirequest.cs │ │ ├── Smo │ │ │ ├── AbstractCollectionBase.cs │ │ │ ├── AffinityInfo.cs │ │ │ ├── AffinityInfoBase.cs │ │ │ ├── AffinityInfoCollection.cs │ │ │ ├── AlertBase.cs │ │ │ ├── AlertCategoryBase.cs │ │ │ ├── AlertSystemBase.cs │ │ │ ├── Application.cs │ │ │ ├── ApplicationRoleBase.cs │ │ │ ├── AssemblyInfo.cs │ │ │ ├── AsymmetricKeyBase.cs │ │ │ ├── AuditBase.cs │ │ │ ├── AuditExtender.cs │ │ │ ├── AuditSpecification.cs │ │ │ ├── AvailabilityDatabaseBase.cs │ │ │ ├── AvailabilityGroupBase.cs │ │ │ ├── AvailabilityGroupListenerBase.cs │ │ │ ├── AvailabilityGroupListenerIPAddressBase.cs │ │ │ ├── AvailabilityGroupListenerIPAddressCollectionBase.cs │ │ │ ├── AvailabilityReplicaBase.cs │ │ │ ├── BackupDeviceBase.cs │ │ │ ├── BackupMedia.cs │ │ │ ├── BackupSet.cs │ │ │ ├── BackupSetCollection.cs │ │ │ ├── BrokerLocalizableResources.strings │ │ │ ├── BrokerPriorityBase.cs │ │ │ ├── BrokerServiceBase.cs │ │ │ ├── CPUBase.cs │ │ │ ├── CategoryBase.cs │ │ │ ├── CertificateBase.cs │ │ │ ├── CheckBase.cs │ │ │ ├── CollationInfo.cs │ │ │ ├── CollectionBase.cs │ │ │ ├── Collections │ │ │ │ ├── AlertCategoryCollection.cs │ │ │ │ ├── AlertCollection.cs │ │ │ │ ├── ApplicationRoleCollection.cs │ │ │ │ ├── AsymmetricKeyCollection.cs │ │ │ │ ├── AuditCollection.cs │ │ │ │ ├── AvailabilityDatabaseCollection.cs │ │ │ │ ├── AvailabilityGroupCollection.cs │ │ │ │ ├── AvailabilityGroupListenerCollection.cs │ │ │ │ ├── AvailabilityGroupListenerIPAddressCollection.cs │ │ │ │ ├── AvailabilityReplicaCollection.cs │ │ │ │ ├── BackupDeviceCollection.cs │ │ │ │ ├── BrokerPriorityCollection.cs │ │ │ │ ├── BrokerServiceCollection.cs │ │ │ │ ├── CertificateCollection.cs │ │ │ │ ├── CheckCollection.cs │ │ │ │ ├── ColumnCollection.cs │ │ │ │ ├── ColumnEncryptionKeyCollection.cs │ │ │ │ ├── ColumnEncryptionKeyValueCollection.cs │ │ │ │ ├── ColumnMasterKeyCollection.cs │ │ │ │ ├── ConfigurationValueCollection.cs │ │ │ │ ├── CredentialCollection.cs │ │ │ │ ├── CryptographicProviderCollection.cs │ │ │ │ ├── DataFileCollection.cs │ │ │ │ ├── DatabaseAuditSpecificationCollection.cs │ │ │ │ ├── DatabaseCollection.cs │ │ │ │ ├── DatabaseDdlTriggerCollection.cs │ │ │ │ ├── DatabaseReplicaStateCollection.cs │ │ │ │ ├── DatabaseRoleCollection.cs │ │ │ │ ├── DatabaseScopedConfigurationCollection.cs │ │ │ │ ├── DatabaseScopedCredentialCollection.cs │ │ │ │ ├── DefaultCollection.cs │ │ │ │ ├── EdgeCollection.cs │ │ │ │ ├── EdgeConstraintClauseCollection.cs │ │ │ │ ├── EdgeConstraintCollection.cs │ │ │ │ ├── EndpointCollection.cs │ │ │ │ ├── ExtendedPropertyCollection.cs │ │ │ │ ├── ExtendedStoredProcedureCollection.cs │ │ │ │ ├── ExternalDataSourceCollection.cs │ │ │ │ ├── ExternalFileFormatCollection.cs │ │ │ │ ├── ExternalLanguageCollection.cs │ │ │ │ ├── ExternalLanguageFileCollection.cs │ │ │ │ ├── ExternalLibraryCollection.cs │ │ │ │ ├── ExternalResourcePoolCollection.cs │ │ │ │ ├── ExternalStreamCollection.cs │ │ │ │ ├── ExternalStreamingJobCollection.cs │ │ │ │ ├── FileGroupCollection.cs │ │ │ │ ├── ForeignKeyCollection.cs │ │ │ │ ├── ForeignKeyColumnCollection.cs │ │ │ │ ├── FullTextCatalogCollection.cs │ │ │ │ ├── FullTextIndexColumnCollection.cs │ │ │ │ ├── FullTextStopListCollection.cs │ │ │ │ ├── IndexCollection.cs │ │ │ │ ├── IndexedColumnCollection.cs │ │ │ │ ├── IndexedXmlPathCollection.cs │ │ │ │ ├── IndexedXmlPathNamespaceCollection.cs │ │ │ │ ├── JobCategoryCollection.cs │ │ │ │ ├── JobScheduleCollection.cs │ │ │ │ ├── JobStepCollection.cs │ │ │ │ ├── LanguageCollection.cs │ │ │ │ ├── LinkedServerCollection.cs │ │ │ │ ├── LinkedServerLoginCollection.cs │ │ │ │ ├── LogFileCollection.cs │ │ │ │ ├── LoginCollection.cs │ │ │ │ ├── MailAccountCollection.cs │ │ │ │ ├── MailProfileCollection.cs │ │ │ │ ├── MailServerCollection.cs │ │ │ │ ├── MessageTypeCollection.cs │ │ │ │ ├── MessageTypeMappingCollection.cs │ │ │ │ ├── NumberedStoredProcedureCollection.cs │ │ │ │ ├── NumberedStoredProcedureParameterCollection.cs │ │ │ │ ├── OleDbProviderSettingsCollection.cs │ │ │ │ ├── OperatorCategoryCollection.cs │ │ │ │ ├── OperatorCollection.cs │ │ │ │ ├── OrderColumnCollection.cs │ │ │ │ ├── PartitionFunctionCollection.cs │ │ │ │ ├── PartitionFunctionParameterCollection.cs │ │ │ │ ├── PartitionSchemeCollection.cs │ │ │ │ ├── PartitionSchemeParameterCollection.cs │ │ │ │ ├── PhysicalPartitionCollection.cs │ │ │ │ ├── PlanGuideCollection.cs │ │ │ │ ├── ProxyAccountCollection.cs │ │ │ │ ├── RemoteServiceBindingCollection.cs │ │ │ │ ├── ResourcePoolCollection.cs │ │ │ │ ├── ResumableIndexCollection.cs │ │ │ │ ├── RuleCollection.cs │ │ │ │ ├── SchemaCollection.cs │ │ │ │ ├── SearchPropertyCollection.cs │ │ │ │ ├── SearchPropertyListCollection.cs │ │ │ │ ├── SecurityPolicyCollection.cs │ │ │ │ ├── SecurityPredicateCollection.cs │ │ │ │ ├── SensitivityClassificationCollection.cs │ │ │ │ ├── SequenceCollection.cs │ │ │ │ ├── ServerAuditSpecificationCollection.cs │ │ │ │ ├── ServerDdlTriggerCollection.cs │ │ │ │ ├── ServerRoleCollection.cs │ │ │ │ ├── ServiceContractCollection.cs │ │ │ │ ├── ServiceContractMappingCollection.cs │ │ │ │ ├── ServiceQueueCollection.cs │ │ │ │ ├── ServiceRouteCollection.cs │ │ │ │ ├── SoapPayloadMethodCollection.cs │ │ │ │ ├── SqlAssemblyCollection.cs │ │ │ │ ├── SqlAssemblyFileCollection.cs │ │ │ │ ├── StatisticCollection.cs │ │ │ │ ├── StatisticColumnCollection.cs │ │ │ │ ├── StoredProcedureCollection.cs │ │ │ │ ├── StoredProcedureParameterCollection.cs │ │ │ │ ├── SymmetricKeyCollection.cs │ │ │ │ ├── SynonymCollection.cs │ │ │ │ ├── SystemDataTypeCollection.cs │ │ │ │ ├── SystemMessageCollection.cs │ │ │ │ ├── TableCollection.cs │ │ │ │ ├── TargetServerCollection.cs │ │ │ │ ├── TargetServerGroupCollection.cs │ │ │ │ ├── TriggerCollection.cs │ │ │ │ ├── UserCollection.cs │ │ │ │ ├── UserDefinedAggregateCollection.cs │ │ │ │ ├── UserDefinedAggregateParameterCollection.cs │ │ │ │ ├── UserDefinedDataTypeCollection.cs │ │ │ │ ├── UserDefinedFunctionCollection.cs │ │ │ │ ├── UserDefinedFunctionParameterCollection.cs │ │ │ │ ├── UserDefinedMessageCollection.cs │ │ │ │ ├── UserDefinedTableTypeCollection.cs │ │ │ │ ├── UserDefinedTypeCollection.cs │ │ │ │ ├── ViewCollection.cs │ │ │ │ ├── WorkloadGroupCollection.cs │ │ │ │ ├── WorkloadManagementWorkloadClassifierCollection.cs │ │ │ │ ├── WorkloadManagementWorkloadGroupCollection.cs │ │ │ │ └── XmlSchemaCollectionCollection.cs │ │ │ ├── ColumnBase.cs │ │ │ ├── ColumnEncryptionKeyBase.cs │ │ │ ├── ColumnEncryptionKeyValueBase.cs │ │ │ ├── ColumnEncryptionKeyValueCollectionBase.cs │ │ │ ├── ColumnMasterKeyBase.cs │ │ │ ├── ConfigProperty.cs │ │ │ ├── Configuration.cs │ │ │ ├── ConfigurationBase.cs │ │ │ ├── ConfigurationValueBase.cs │ │ │ ├── ContractExtender.cs │ │ │ ├── CredentialBase.cs │ │ │ ├── CryptographicProviderBase.cs │ │ │ ├── DataClassificationScriptGenerator.cs │ │ │ ├── DataEnumerator.cs │ │ │ ├── DataScriptCollection.cs │ │ │ ├── DataType.cs │ │ │ ├── DatabaseAuditSpecificationExtender.cs │ │ │ ├── DatabaseAuditSpecificationbase.cs │ │ │ ├── DatabaseBase.cs │ │ │ ├── DatabaseDdlTriggerBase.cs │ │ │ ├── DatabaseEncryptionKeyBase.cs │ │ │ ├── DatabaseEncryptionKeyExtender.cs │ │ │ ├── DatabaseFileMappingsDictionary.cs │ │ │ ├── DatabaseMirroringPayloadBase.cs │ │ │ ├── DatabaseOptionsBase.cs │ │ │ ├── DatabasePrefetch.cs │ │ │ ├── DatabaseReplicaStateBase.cs │ │ │ ├── DatabaseReplicaStateCollectionBase.cs │ │ │ ├── DatabaseRoleBase.cs │ │ │ ├── DatabaseScopedConfigurationBase.cs │ │ │ ├── DatabaseScopedCredentialBase.cs │ │ │ ├── DdlTriggerBase.cs │ │ │ ├── DefaultBase.cs │ │ │ ├── DefaultConstraintBase.cs │ │ │ ├── DefaultRuleBase.cs │ │ │ ├── DependencyList.cs │ │ │ ├── DependencyTree.cs │ │ │ ├── DependencyWalker.cs │ │ │ ├── DistributionColumnBase.cs │ │ │ ├── EdgeConstraintBase.cs │ │ │ ├── EdgeConstraintClauseBase.cs │ │ │ ├── EndpointBase.cs │ │ │ ├── EnumerableContainer.cs │ │ │ ├── EnumeratorContainer.cs │ │ │ ├── ExceptionTemplates.cs │ │ │ ├── ExceptionTemplatesImpl.strings │ │ │ ├── ExecutionManager.cs │ │ │ ├── ExtendedPropertyBase.cs │ │ │ ├── ExtendedStoredProcedureBase.cs │ │ │ ├── ExtensionClass.cs │ │ │ ├── ExternalDataSourceBase.cs │ │ │ ├── ExternalFileFormatBase.cs │ │ │ ├── ExternalLanguageBase.cs │ │ │ ├── ExternalLanguageFileBase.cs │ │ │ ├── ExternalLibraryBase.cs │ │ │ ├── ExternalLibraryFileBase.cs │ │ │ ├── ExternalResourcePoolAffinityInfo.cs │ │ │ ├── ExternalResourcePoolBase.cs │ │ │ ├── ExternalStreamBase.cs │ │ │ ├── ExternalStreamingJobBase.cs │ │ │ ├── FacetSR.strings │ │ │ ├── Facets │ │ │ │ ├── AvailabilityGroupState.cs │ │ │ │ ├── DatabaseAdapter.cs │ │ │ │ ├── DatabaseMaintenance.cs │ │ │ │ ├── DatabasePerformance.cs │ │ │ │ ├── DatabaseSecurity.cs │ │ │ │ ├── MultiPartName.cs │ │ │ │ ├── Name.cs │ │ │ │ ├── ServerAdapter.cs │ │ │ │ ├── ServerAudit.cs │ │ │ │ ├── ServerConfiguration.cs │ │ │ │ ├── ServerPerformance.cs │ │ │ │ ├── ServerSecurity.cs │ │ │ │ ├── ServerSelection.cs │ │ │ │ ├── ServerSetup.cs │ │ │ │ ├── ServerSurfaceArea.cs │ │ │ │ └── SmartAdminState.cs │ │ │ ├── FilePerObjectWriter.cs │ │ │ ├── ForeignKeyBase.cs │ │ │ ├── ForeignKeyColumnBase.cs │ │ │ ├── FullTextCatalogBase.cs │ │ │ ├── FullTextIndexBase.cs │ │ │ ├── FullTextIndexColumnBase.cs │ │ │ ├── FullTextServiceBase.cs │ │ │ ├── FullTextStopListBase.cs │ │ │ ├── FxCopExclusions.cs │ │ │ ├── HttpProtocolBase.cs │ │ │ ├── IDatabaseOptions.cs │ │ │ ├── ILoginOptions.cs │ │ │ ├── IServerInformation.cs │ │ │ ├── IServerSettings.cs │ │ │ ├── ITableOptions.cs │ │ │ ├── IUserOptions.cs │ │ │ ├── IViewOptions.cs │ │ │ ├── IndexBase.cs │ │ │ ├── IndexScripter.cs │ │ │ ├── IndexedColumnBase.cs │ │ │ ├── IndexedXmlPathBase.cs │ │ │ ├── IndexedXmlPathNamespaceBase.cs │ │ │ ├── InformationBase.cs │ │ │ ├── JobBase.cs │ │ │ ├── JobCategoryBase.cs │ │ │ ├── JobScheduleBase.cs │ │ │ ├── JobScheduleCollectionBase.cs │ │ │ ├── JobServerBase.cs │ │ │ ├── JobStepBase.cs │ │ │ ├── KeyEncryptionBase.cs │ │ │ ├── LanguageBase.cs │ │ │ ├── LinkedServerBase.cs │ │ │ ├── LinkedServerLoginBase.cs │ │ │ ├── LocalizableResources.strings │ │ │ ├── LoginBase.cs │ │ │ ├── MailAccountBase.cs │ │ │ ├── MailProfileBase.cs │ │ │ ├── MailServerBase.cs │ │ │ ├── MasterKeyBase.cs │ │ │ ├── MessageCollectionBase.cs │ │ │ ├── MessageObjectBase.cs │ │ │ ├── MessageTypeBase.cs │ │ │ ├── MessageTypeMappingBase.cs │ │ │ ├── Microsoft.SqlServer.Smo.csproj │ │ │ ├── ModuleSuppressions.cs │ │ │ ├── NetCoreHelpers.cs │ │ │ ├── NumaNodeBase.cs │ │ │ ├── NumberedCollectionBase.cs │ │ │ ├── OleDbProviderSettingsBase.cs │ │ │ ├── OperatorBase.cs │ │ │ ├── OperatorCategoryBase.cs │ │ │ ├── OrderColumnBase.cs │ │ │ ├── ParamBase.cs │ │ │ ├── ParameterCollectionBase.cs │ │ │ ├── PartitionFunctionBase.cs │ │ │ ├── PartitionFunctionParameterBase.cs │ │ │ ├── PartitionSchemeBase.cs │ │ │ ├── PartitionSchemeParameterBase.cs │ │ │ ├── PhysicalPartitionBase.cs │ │ │ ├── PhysicalPartitionCollectionBase.cs │ │ │ ├── PlanGuideBase.cs │ │ │ ├── PlanGuideExtender.cs │ │ │ ├── ProxyAccountBase.cs │ │ │ ├── QueryStoreEnums.cs │ │ │ ├── QueryStoreOptions.cs │ │ │ ├── RemoteDataArchiveMigrationState.cs │ │ │ ├── RemoteDataArchiveMigrationStatusReport.cs │ │ │ ├── RemoteDatabaseMigrationStatistics.cs │ │ │ ├── RemoteServiceBindingBase.cs │ │ │ ├── RemoteTableMigrationStatistics.cs │ │ │ ├── ResourceGovernorBase.cs │ │ │ ├── ResourcePoolAffinityInfo.cs │ │ │ ├── ResourcePoolBase.cs │ │ │ ├── ResumableIndexBase.cs │ │ │ ├── RuleBase.cs │ │ │ ├── SchedulerBase.cs │ │ │ ├── SchemaBase.cs │ │ │ ├── SchemaCollectionBase.cs │ │ │ ├── ScriptContainer.cs │ │ │ ├── ScriptContainerFactory.cs │ │ │ ├── ScriptMaker.cs │ │ │ ├── ScriptNameObjectBase.cs │ │ │ ├── ScriptSchemaObjectBase.cs │ │ │ ├── ScriptStringBuilder │ │ │ │ ├── IScriptStringBuilderParameter.cs │ │ │ │ ├── ParameterValueFormat.cs │ │ │ │ ├── ScriptStringBuilder.cs │ │ │ │ ├── ScriptStringBuilderObjectParameter.cs │ │ │ │ └── ScriptStringBuilderParameter.cs │ │ │ ├── Scripter.cs │ │ │ ├── ScriptingInterfaces.cs │ │ │ ├── ScriptingOptions.cs │ │ │ ├── ScriptingPreferences.cs │ │ │ ├── SearchPropertyBase.cs │ │ │ ├── SearchPropertyListBase.cs │ │ │ ├── SearchPropertyListConstants.cs │ │ │ ├── SearchPropertyListExtender.cs │ │ │ ├── SearchPropertyListValidator.cs │ │ │ ├── SecurityPolicyBase.cs │ │ │ ├── SecurityPredicateBase.cs │ │ │ ├── SecurityPredicateCollectionBase.cs │ │ │ ├── SecurityUtils.cs │ │ │ ├── SensitivityClassificationBase.cs │ │ │ ├── SequenceBase.cs │ │ │ ├── SequenceExtender.cs │ │ │ ├── SerializationAdapters.cs │ │ │ ├── ServerAuditSpecificationExtender.cs │ │ │ ├── ServerAuditSpecificationbase.cs │ │ │ ├── ServerDdlTriggerBase.cs │ │ │ ├── ServerEventsWorker.cs │ │ │ ├── ServerProxyAccountBase.cs │ │ │ ├── ServerRoleBase.cs │ │ │ ├── ServerRoleExtender.cs │ │ │ ├── ServiceBrokerBase.cs │ │ │ ├── ServiceBrokerExtender.cs │ │ │ ├── ServiceBrokerPayloadBase.cs │ │ │ ├── ServiceContractBase.cs │ │ │ ├── ServiceContractMappingBase.cs │ │ │ ├── ServiceMasterKeyBase.cs │ │ │ ├── ServiceQueueBase.cs │ │ │ ├── ServiceRouteBase.cs │ │ │ ├── ServiceType.cs │ │ │ ├── SettingsBase.cs │ │ │ ├── SfcResolver.cs │ │ │ ├── SingleFileWriter.cs │ │ │ ├── SingleFileWriterBase.cs │ │ │ ├── SmartAdminBase.cs │ │ │ ├── SmoArrayList.cs │ │ │ ├── SmoCollectionBase.cs │ │ │ ├── SmoComparer.cs │ │ │ ├── SmoDependencyDiscoverer.cs │ │ │ ├── SmoDependencyOrderer.cs │ │ │ ├── SmoDiffAdapters.cs │ │ │ ├── SmoObjectBase.cs │ │ │ ├── SmoSet.cs │ │ │ ├── SmoSortedList.cs │ │ │ ├── SmoStringWriter.cs │ │ │ ├── SmoUrnFilter.cs │ │ │ ├── SmoUtility.cs │ │ │ ├── SoapMethodCollectionBase.cs │ │ │ ├── SoapMethodObject.cs │ │ │ ├── SoapPayloadBase.cs │ │ │ ├── SoapPayloadMethodBase.cs │ │ │ ├── SqlAssemblyBase.cs │ │ │ ├── SqlAssemblyFileBase.cs │ │ │ ├── SqlMailBase.cs │ │ │ ├── SqlSmoObject.cs │ │ │ ├── StatisticBase.cs │ │ │ ├── StatisticColumnBase.cs │ │ │ ├── SymmetricKeyBase.cs │ │ │ ├── SynonymBase.cs │ │ │ ├── SystemDataTypeBase.cs │ │ │ ├── SystemMessageBase.cs │ │ │ ├── TableViewBase.cs │ │ │ ├── TableViewTableTypeBase.cs │ │ │ ├── TargetServerBase.cs │ │ │ ├── TargetServerGroupBase.cs │ │ │ ├── TcpProtocolBase.cs │ │ │ ├── TestModel.cs │ │ │ ├── TraceHelper.cs │ │ │ ├── TriggerBase.cs │ │ │ ├── UserBase.cs │ │ │ ├── UserDefinedAggregateBase.cs │ │ │ ├── UserDefinedAggregateParameterBase.cs │ │ │ ├── UserDefinedFunctionBase.cs │ │ │ ├── UserDefinedMessageBase.cs │ │ │ ├── UserDefinedTableTypebase.cs │ │ │ ├── UserDefinedTypeBase.cs │ │ │ ├── UserOptionBase.cs │ │ │ ├── UserPermission.cs │ │ │ ├── UserPermissionBase.cs │ │ │ ├── UserPermissionCollection.cs │ │ │ ├── VersionUtils.cs │ │ │ ├── ViewBase.cs │ │ │ ├── WorkloadGroupBase.cs │ │ │ ├── WorkloadManagementWorkloadClassifierBase.cs │ │ │ ├── WorkloadManagementWorkloadGroupBase.cs │ │ │ ├── XmlSchemaCollectionBase.cs │ │ │ ├── availability_group_listener_ipaddress_generic_collection.cs │ │ │ ├── coll_macros.h │ │ │ ├── columnencryptionkeyvalue_generic_collection.cs │ │ │ ├── database_replica_state_generic_collection.cs │ │ │ ├── databasesnapshotextender.cs │ │ │ ├── dmf.cs │ │ │ ├── enumerations.cs │ │ │ ├── exception.cs │ │ │ ├── files.cs │ │ │ ├── generic_collection.cs │ │ │ ├── message_generic_collection.cs │ │ │ ├── numbered_generic_collection.cs │ │ │ ├── numberedstoredprocedurebase.cs │ │ │ ├── ordinal_generic_collection.cs │ │ │ ├── param_generic_collection.cs │ │ │ ├── permissionInterfaces.cs │ │ │ ├── permissionOptions.cs │ │ │ ├── permissionWorker.cs │ │ │ ├── physicalpartitionsegment_generic_collection.cs │ │ │ ├── properties.cs │ │ │ ├── propertiesCollection.cs │ │ │ ├── propertiesMetadata.cs │ │ │ ├── schedule_generic_collection.cs │ │ │ ├── schema_generic_collection.cs │ │ │ ├── script_patterns.cs │ │ │ ├── securitypredicate_generic_collection.cs │ │ │ ├── serverbase.cs │ │ │ ├── smoobjectextender.cs │ │ │ ├── soapmethod_generic_collection.cs │ │ │ ├── sqlexec.cs │ │ │ ├── storedprocedurebase.cs │ │ │ ├── tablebase.cs │ │ │ └── uddtbase.cs │ │ ├── SmoMetadataProvider │ │ │ ├── ApplicationRole.cs │ │ │ ├── AsymmetricKey.cs │ │ │ ├── Certificate.cs │ │ │ ├── CheckConstraint.cs │ │ │ ├── Column.cs │ │ │ ├── Config.cs │ │ │ ├── ConnectedSmoMetadataProvider.cs │ │ │ ├── Credential.cs │ │ │ ├── Database.cs │ │ │ ├── DatabaseDdlTrigger.cs │ │ │ ├── DatabaseObject.cs │ │ │ ├── DatabaseObjectBase.cs │ │ │ ├── DatabaseOwnedObject.cs │ │ │ ├── DatabasePermission.cs │ │ │ ├── DatabasePrincipal.cs │ │ │ ├── DatabaseRole.cs │ │ │ ├── DefaultConstraint.cs │ │ │ ├── DisconnectedSmoMetadataProvider.cs │ │ │ ├── DmlTrigger.cs │ │ │ ├── ExtendedStoredProcedure.cs │ │ │ ├── ForeignKeyConstraint.cs │ │ │ ├── ISmoDatabaseObject.cs │ │ │ ├── Index.cs │ │ │ ├── Login.cs │ │ │ ├── Microsoft.SqlServer.Management.SmoMetadataProvider.csproj │ │ │ ├── PrimaryKeyConstraint.cs │ │ │ ├── RelationalIndex.cs │ │ │ ├── ScalarValuedFunction.cs │ │ │ ├── Schema.cs │ │ │ ├── SchemaOwnedModule.cs │ │ │ ├── SchemaOwnedObject.cs │ │ │ ├── Server.cs │ │ │ ├── ServerDdlTrigger.cs │ │ │ ├── ServerOwnedObject.cs │ │ │ ├── SmoBuiltInFunctionLookup.cs │ │ │ ├── SmoCollationLookup.cs │ │ │ ├── SmoMetadataFactory.cs │ │ │ ├── SmoMetadataProvider.cs │ │ │ ├── SmoSystemDataTypeLookup.cs │ │ │ ├── SpatialIndex.cs │ │ │ ├── Statistics.cs │ │ │ ├── StoredProcedure.cs │ │ │ ├── Synonym.cs │ │ │ ├── Table.cs │ │ │ ├── TableValuedFunction.cs │ │ │ ├── TableViewBase.cs │ │ │ ├── TableViewTableTypeBase.cs │ │ │ ├── TraceHelper.cs │ │ │ ├── UniqueConstraint.cs │ │ │ ├── UniqueConstraintBase.cs │ │ │ ├── User.cs │ │ │ ├── UserDefinedAggregate.cs │ │ │ ├── UserDefinedClrType.cs │ │ │ ├── UserDefinedDataType.cs │ │ │ ├── UserDefinedFunction.cs │ │ │ ├── UserDefinedTableType.cs │ │ │ ├── Utils.cs │ │ │ ├── View.cs │ │ │ └── XmlIndex.cs │ │ ├── SqlAssessment │ │ │ ├── Microsoft.SqlServer.Management.Assessment.csproj │ │ │ └── SqlAssessmentExtensions.cs │ │ ├── SqlEnum │ │ │ ├── AssemblyInfo.cs │ │ │ ├── AvailableSQLServers.CS │ │ │ ├── ConditionedSql.cs │ │ │ ├── DataProvider.cs │ │ │ ├── DatabaseLevel.CS │ │ │ ├── DatabaseOption.cs │ │ │ ├── DdlParser.cs │ │ │ ├── EventSetBase.cs │ │ │ ├── FxCopExclusions.cs │ │ │ ├── Microsoft.SqlServer.SqlEnum.csproj │ │ │ ├── PostProcess.cs │ │ │ ├── PostProcessAuditProperties.cs │ │ │ ├── PostProcessCreateDateTime.cs │ │ │ ├── PostProcessDatabaseInsideAttribs.cs │ │ │ ├── PostProcessEvents.cs │ │ │ ├── PostProcessFile.cs │ │ │ ├── PostProcessOwner.cs │ │ │ ├── PostProcessParam.cs │ │ │ ├── PostProcessRemoteDataArchiveDatabaseProperties.cs │ │ │ ├── PostProcessTable.cs │ │ │ ├── PostProcessText.cs │ │ │ ├── PostProcessUser.cs │ │ │ ├── PostProcessVersion.cs │ │ │ ├── PostProcessWithRowCaching.cs │ │ │ ├── PostProcessXml.cs │ │ │ ├── QueryIsolation.cs │ │ │ ├── RequestParentSelect.cs │ │ │ ├── Server.cs │ │ │ ├── SqlConditionedStatement.cs │ │ │ ├── SqlEnumDependencies.cs │ │ │ ├── SqlEnumNetCoreExtension.cs │ │ │ ├── SqlEnumStatementBuilderTestHook.cs │ │ │ ├── SqlLinkMultiple.cs │ │ │ ├── SqlObject.cs │ │ │ ├── SqlObjectBase.cs │ │ │ ├── SqlObjectProperty.cs │ │ │ ├── SqlObjectUnion.cs │ │ │ ├── SqlParentLink.cs │ │ │ ├── SqlPostProcess.cs │ │ │ ├── SqlPropertyLink.cs │ │ │ ├── SqlRequest.cs │ │ │ ├── SqlUtil.cs │ │ │ ├── StringSqlEnumerator.strings │ │ │ ├── TypeConverters.cs │ │ │ ├── Util.cs │ │ │ ├── XmlRead.CS │ │ │ ├── diskfile.cs │ │ │ ├── enumstructs.cs │ │ │ ├── executesql.cs │ │ │ ├── permenum.cs │ │ │ ├── primaryfile.cs │ │ │ ├── restoreplan.cs │ │ │ ├── sqlenumresult.cs │ │ │ ├── sqlsecurestring.cs │ │ │ ├── statementbuilder.cs │ │ │ └── xml │ │ │ │ ├── AditionalParameters.xml │ │ │ │ ├── AffinityInfo.xml │ │ │ │ ├── AgentPerfInfo.xml │ │ │ │ ├── AgentSubSystems.xml │ │ │ │ ├── AlertNotification.xml │ │ │ │ ├── ApplicationRole.xml │ │ │ │ ├── AsymmetricKey.xml │ │ │ │ ├── Audit.xml │ │ │ │ ├── AvailabilityDatabase.xml │ │ │ │ ├── AvailabilityGroup.xml │ │ │ │ ├── AvailabilityGroupListener.xml │ │ │ │ ├── AvailabilityGroupListenerIPAddress.xml │ │ │ │ ├── AvailabilityReplica.xml │ │ │ │ ├── AvailableMedia.xml │ │ │ │ ├── BackupDevice.xml │ │ │ │ ├── BoundColumn.xml │ │ │ │ ├── CdromDrive.xml │ │ │ │ ├── CloudDependency.sql │ │ │ │ ├── ClusterMemberState.xml │ │ │ │ ├── ColumnEncryptionKey.xml │ │ │ │ ├── ColumnEncryptionKeyValue.xml │ │ │ │ ├── ColumnMasterKey.xml │ │ │ │ ├── ComputedText.xml │ │ │ │ ├── Configuration.xml │ │ │ │ ├── ConfigurationValue.xml │ │ │ │ ├── Connection.xml │ │ │ │ ├── Credential.xml │ │ │ │ ├── CryptographicProvider.xml │ │ │ │ ├── Database.xml │ │ │ │ ├── DatabaseAuditSpecification.xml │ │ │ │ ├── DatabaseAuditSpecificationDetail.xml │ │ │ │ ├── DatabaseDdlTrigger.xml │ │ │ │ ├── DatabaseDdlTriggerEvent.xml │ │ │ │ ├── DatabaseDiagram.xml │ │ │ │ ├── DatabaseEncryptionKey.xml │ │ │ │ ├── DatabaseLocks.xml │ │ │ │ ├── DatabaseMappings.xml │ │ │ │ ├── DatabaseMasterKey.xml │ │ │ │ ├── DatabaseMirroringWitnessRole.xml │ │ │ │ ├── DatabaseOptions.xml │ │ │ │ ├── DatabaseReplicaState.xml │ │ │ │ ├── DatabaseRole.xml │ │ │ │ ├── DatabaseRoleMember.xml │ │ │ │ ├── DatabaseScopedConfiguration.xml │ │ │ │ ├── DatabaseScopedCredential.xml │ │ │ │ ├── DbExtendedProperty.xml │ │ │ │ ├── Default.xml │ │ │ │ ├── DefaultColumn.xml │ │ │ │ ├── DefaultConstrain.xml │ │ │ │ ├── DefaultDatatype.xml │ │ │ │ ├── DiskFile.xml │ │ │ │ ├── DistributionColumn.xml │ │ │ │ ├── Drive.xml │ │ │ │ ├── ErrorLog.xml │ │ │ │ ├── ErrorLogText.xml │ │ │ │ ├── ExternalDataSource.xml │ │ │ │ ├── ExternalFileFormat.xml │ │ │ │ ├── ExternalLanguage.xml │ │ │ │ ├── ExternalLanguageFile.xml │ │ │ │ ├── ExternalLibrary.xml │ │ │ │ ├── ExternalLibraryFile.xml │ │ │ │ ├── ExternalResourcePool.xml │ │ │ │ ├── ExternalResourcePoolAffinityInfo.xml │ │ │ │ ├── ExternalStream.xml │ │ │ │ ├── ExternalStreamingJob.xml │ │ │ │ ├── FKColumn.xml │ │ │ │ ├── File.xml │ │ │ │ ├── FileGroup.xml │ │ │ │ ├── FixedDrive.xml │ │ │ │ ├── ForeignKey.xml │ │ │ │ ├── FullTextCatalog.xml │ │ │ │ ├── FullTextFile.xml │ │ │ │ ├── FullTextIndex.xml │ │ │ │ ├── FullTextIndexColumn.xml │ │ │ │ ├── FullTextLanguage.xml │ │ │ │ ├── FullTextService.xml │ │ │ │ ├── FullTextStopList.xml │ │ │ │ ├── FulltextSemanticLanguage.xml │ │ │ │ ├── IndexFragDetail.xml │ │ │ │ ├── IndexFragFast.xml │ │ │ │ ├── IndexFragSampled.xml │ │ │ │ ├── IndexedColumn.xml │ │ │ │ ├── IndexedXmlPath.xml │ │ │ │ ├── IndexedXmlPathNamespace.xml │ │ │ │ ├── Information.xml │ │ │ │ ├── Job.xml │ │ │ │ ├── JobServer.xml │ │ │ │ ├── JobStepOutputLog.xml │ │ │ │ ├── KatmaiDependency.sql │ │ │ │ ├── KeyEncryption.xml │ │ │ │ ├── Lock.xml │ │ │ │ ├── LogFile.xml │ │ │ │ ├── LogMarkHistory.xml │ │ │ │ ├── Mail.xml │ │ │ │ ├── MailAccount.xml │ │ │ │ ├── MailProfile.xml │ │ │ │ ├── MailProfileAccounts.xml │ │ │ │ ├── MailProfilePrincipals.xml │ │ │ │ ├── MailServer.xml │ │ │ │ ├── Mail_ErrorLog.xml │ │ │ │ ├── MaintSubPlanLog.xml │ │ │ │ ├── MaintSubPlanLogDetail.xml │ │ │ │ ├── MaintenancePlan.xml │ │ │ │ ├── MaintenancePlanDeprecated.xml │ │ │ │ ├── MaintenanceSubPlan.xml │ │ │ │ ├── MasterKeyEncryption.xml │ │ │ │ ├── Member.xml │ │ │ │ ├── NTGroup.xml │ │ │ │ ├── NTLogin.xml │ │ │ │ ├── NotificationServices │ │ │ │ ├── Application.xml │ │ │ │ ├── ApplicationDatabaseFile.xml │ │ │ │ ├── ApplicationDatabaseFileGroup.xml │ │ │ │ ├── ApplicationDatabaseLogFile.xml │ │ │ │ ├── ApplicationDatabaseOptions.xml │ │ │ │ ├── ContentFormatter.xml │ │ │ │ ├── ContentFormatterArgument.xml │ │ │ │ ├── DeliveryChannel.xml │ │ │ │ ├── DeliveryChannelArgument.xml │ │ │ │ ├── Distributor.xml │ │ │ │ ├── EventChronicle.xml │ │ │ │ ├── EventChronicleRule.xml │ │ │ │ ├── EventClass.xml │ │ │ │ ├── EventField.xml │ │ │ │ ├── Generator.xml │ │ │ │ ├── HostedEventProvider.xml │ │ │ │ ├── HostedEventProviderArgument.xml │ │ │ │ ├── Instance.xml │ │ │ │ ├── InstanceDatabaseFile.xml │ │ │ │ ├── InstanceDatabaseFileGroup.xml │ │ │ │ ├── InstanceDatabaseLogFile.xml │ │ │ │ ├── InstanceDatabaseOptions.xml │ │ │ │ ├── NonHostedEventProvider.xml │ │ │ │ ├── NotificationClass.xml │ │ │ │ ├── NotificationClassProtocol.xml │ │ │ │ ├── NotificationComputedField.xml │ │ │ │ ├── NotificationField.xml │ │ │ │ ├── NotificationServices.xml │ │ │ │ ├── ProtocolDefinition.xml │ │ │ │ ├── ProtocolField.xml │ │ │ │ ├── ProtocolRetrySchedule.xml │ │ │ │ ├── SubscriptionChronicle.xml │ │ │ │ ├── SubscriptionClass.xml │ │ │ │ ├── SubscriptionConditionEventRule.xml │ │ │ │ ├── SubscriptionConditionScheduledRule.xml │ │ │ │ ├── SubscriptionEventRule.xml │ │ │ │ ├── SubscriptionField.xml │ │ │ │ ├── SubscriptionScheduledRule.xml │ │ │ │ └── VacuumSchedule.xml │ │ │ │ ├── NumberedSPParams.xml │ │ │ │ ├── NumberedStoredProcedure.xml │ │ │ │ ├── OLEDBProvProp.xml │ │ │ │ ├── OLEDBProvider.xml │ │ │ │ ├── OLEDBProviderSetting.xml │ │ │ │ ├── OperatorJobNotification.xml │ │ │ │ ├── OperatorNotification.xml │ │ │ │ ├── OrderColumn.xml │ │ │ │ ├── PartitionFunction.xml │ │ │ │ ├── PartitionFunctionParameter.xml │ │ │ │ ├── PartitionFunctionRangeValue.xml │ │ │ │ ├── PartitionScheme.xml │ │ │ │ ├── PartitionSchemeFileGroup.xml │ │ │ │ ├── PartitionSchemeParameter.xml │ │ │ │ ├── PerfInfo.xml │ │ │ │ ├── PhysicalPartition.xml │ │ │ │ ├── PlanGuide.xml │ │ │ │ ├── Process.xml │ │ │ │ ├── ProxyAccount.xml │ │ │ │ ├── ProxyAccountPrincipals.xml │ │ │ │ ├── QueryStoreOptions.xml │ │ │ │ ├── README.md │ │ │ │ ├── RemoteDrive.xml │ │ │ │ ├── RemoteMaintenancePlan.xml │ │ │ │ ├── RemotePlanLog.xml │ │ │ │ ├── RemotePlanLogDetail.xml │ │ │ │ ├── RemoteSubPlan.xml │ │ │ │ ├── RemovableDrive.xml │ │ │ │ ├── ReplicaClusterNode.xml │ │ │ │ ├── ResourceGovernor.xml │ │ │ │ ├── ResourcePool.xml │ │ │ │ ├── ResourcePoolAffinityInfo.xml │ │ │ │ ├── ResourcePoolScheduler.xml │ │ │ │ ├── Rule.xml │ │ │ │ ├── RuleColumn.xml │ │ │ │ ├── RuleDatatype.xml │ │ │ │ ├── SPParams.xml │ │ │ │ ├── SPPerm.xml │ │ │ │ ├── SQL11Dependency.sql │ │ │ │ ├── SQL13Dependency.sql │ │ │ │ ├── Schema.xml │ │ │ │ ├── SearchProperty.xml │ │ │ │ ├── SearchPropertyList.xml │ │ │ │ ├── SecurityPolicy.xml │ │ │ │ ├── SecurityPredicate.xml │ │ │ │ ├── SensitivityClassification.xml │ │ │ │ ├── ServerAuditSpecification.xml │ │ │ │ ├── ServerAuditSpecificationDetail.xml │ │ │ │ ├── ServerDdlTrigger.xml │ │ │ │ ├── ServerDdlTriggerEvent.xml │ │ │ │ ├── ServerProxyAccount.xml │ │ │ │ ├── ServerRole.xml │ │ │ │ ├── Settings.xml │ │ │ │ ├── ShilohDependency.sql │ │ │ │ ├── SmartAdmin.xml │ │ │ │ ├── SqlAssembly.xml │ │ │ │ ├── SqlAssemblyFile.xml │ │ │ │ ├── SqlBoot.xml │ │ │ │ ├── StatisticColumn.xml │ │ │ │ ├── StoredProcedure.xml │ │ │ │ ├── SymmetricKey.xml │ │ │ │ ├── TablePerm.xml │ │ │ │ ├── TapeDevice.xml │ │ │ │ ├── Text.xml │ │ │ │ ├── UDF.xml │ │ │ │ ├── UDFParams.xml │ │ │ │ ├── UserDefinedAggregate.xml │ │ │ │ ├── UserDefinedAggregateParameter.xml │ │ │ │ ├── UserDefinedTableType.xml │ │ │ │ ├── UserDefinedType.xml │ │ │ │ ├── UserMessage.xml │ │ │ │ ├── UserOption.xml │ │ │ │ ├── WorkloadGroup.xml │ │ │ │ ├── WorkloadManagementWorkloadClassifier.xml │ │ │ │ ├── WorkloadManagementWorkloadGroup.xml │ │ │ │ ├── XStoredProcedure.xml │ │ │ │ ├── XmlNamespace.xml │ │ │ │ ├── XmlSchemaCollection.xml │ │ │ │ ├── YukonDependency.sql │ │ │ │ ├── Yukonuserownedobject.xml │ │ │ │ ├── YukonuserownedobjectSchema.xml │ │ │ │ ├── agent_ErrorLog.xml │ │ │ │ ├── agent_ErrorLogText.xml │ │ │ │ ├── agent_alert.xml │ │ │ │ ├── agent_alert_categories.xml │ │ │ │ ├── agent_alertsystem.xml │ │ │ │ ├── agent_job_categories.xml │ │ │ │ ├── agent_jobalert.xml │ │ │ │ ├── agent_jobhistory.xml │ │ │ │ ├── agent_jobschedule.xml │ │ │ │ ├── agent_jobtargetservers.xml │ │ │ │ ├── agent_operator.xml │ │ │ │ ├── agent_operator_categories.xml │ │ │ │ ├── agent_targetserver.xml │ │ │ │ ├── agent_targetservergroup.xml │ │ │ │ ├── agent_targetservermember.xml │ │ │ │ ├── backupfile.xml │ │ │ │ ├── backupmediafamily.xml │ │ │ │ ├── backupmediaset.xml │ │ │ │ ├── backupset.xml │ │ │ │ ├── certificate.xml │ │ │ │ ├── check.xml │ │ │ │ ├── clusterSubnet.xml │ │ │ │ ├── collation.xml │ │ │ │ ├── column.xml │ │ │ │ ├── edgeconstraint.xml │ │ │ │ ├── edgeconstraintclause.xml │ │ │ │ ├── endpoint │ │ │ │ ├── database_mirroring_endpoint.xml │ │ │ │ ├── endpoint.xml │ │ │ │ ├── http_endpoint.xml │ │ │ │ ├── service_broker_endpoint.xml │ │ │ │ ├── soap_endpoint.xml │ │ │ │ ├── soap_endpoint_method.xml │ │ │ │ ├── tcp_endpoint.xml │ │ │ │ └── via_endpoint.xml │ │ │ │ ├── extendedproperty │ │ │ │ ├── ExtendedProperty.xml │ │ │ │ ├── Level0ExtendedProperty.xml │ │ │ │ ├── Level1ExtendedProperty.xml │ │ │ │ ├── Level2ExtendedProperty.xml │ │ │ │ ├── Level2IndexExtendedProperty.xml │ │ │ │ ├── inc_level2SupportProperties.xml │ │ │ │ └── inc_shilohExtendedProperty.xml │ │ │ │ ├── fulltext_ErrorLog.xml │ │ │ │ ├── fulltext_ErrorLogText.xml │ │ │ │ ├── inc_DbFile.xml │ │ │ │ ├── inc_DefaultRule_column.xml │ │ │ │ ├── inc_IndexFrag.xml │ │ │ │ ├── inc_assembly_module_link.xml │ │ │ │ ├── inc_column_reference.xml │ │ │ │ ├── inc_constraint.xml │ │ │ │ ├── inc_ddl_trigger_event.xml │ │ │ │ ├── inc_fulltext.xml │ │ │ │ ├── inc_hadr_policy_health_state.xml │ │ │ │ ├── inc_hadr_setting.xml │ │ │ │ ├── inc_named_object.xml │ │ │ │ ├── inc_object.xml │ │ │ │ ├── inc_objprop_table_view.xml │ │ │ │ ├── inc_partition_scheme_parent.xml │ │ │ │ ├── inc_policy_health_state.xml │ │ │ │ ├── inc_ruledef80.xml │ │ │ │ ├── inc_server.xml │ │ │ │ ├── inc_server_sql_module_link.xml │ │ │ │ ├── inc_sql_module.xml │ │ │ │ ├── inc_sql_module_JustText.xml │ │ │ │ ├── inc_storage.xml │ │ │ │ ├── inc_system_object.xml │ │ │ │ ├── inc_system_table_view_sp_udf.xml │ │ │ │ ├── inc_text.xml │ │ │ │ ├── inc_type.xml │ │ │ │ ├── inc_type_reference.xml │ │ │ │ ├── inc_urn.xml │ │ │ │ ├── inc_urn_collate_default.xml │ │ │ │ ├── inc_urn_message.xml │ │ │ │ ├── inc_urn_schema.xml │ │ │ │ ├── inc_urn_single.xml │ │ │ │ ├── inc_urn_soapmethod.xml │ │ │ │ ├── include │ │ │ │ ├── mixed_module_link.xml │ │ │ │ ├── parameter.xml │ │ │ │ └── sql_module_link.xml │ │ │ │ ├── index.xml │ │ │ │ ├── jobstep.xml │ │ │ │ ├── language.xml │ │ │ │ ├── linkedserver.xml │ │ │ │ ├── linkedservercatalog.xml │ │ │ │ ├── linkedserverlogin.xml │ │ │ │ ├── linkedservertable.xml │ │ │ │ ├── linkedserverview.xml │ │ │ │ ├── login.xml │ │ │ │ ├── perm │ │ │ │ ├── ColumnPerm.xml │ │ │ │ ├── DBObjectPerm.xml │ │ │ │ ├── DBPerm.xml │ │ │ │ ├── ShilohYukonPerm.xml │ │ │ │ ├── SrvObjectPerm.xml │ │ │ │ ├── SrvYukonObjectPerm.xml │ │ │ │ ├── SrvYukonPerm.xml │ │ │ │ ├── TablePerm.xml │ │ │ │ ├── YukonObjectPerm.xml │ │ │ │ ├── YukonSchemaObjectPerm.xml │ │ │ │ ├── dbfixedroleperm.xml │ │ │ │ └── inc_perm.xml │ │ │ │ ├── primarychildren.xml │ │ │ │ ├── primaryfile.xml │ │ │ │ ├── restore_plan.xml │ │ │ │ ├── restorefile.xml │ │ │ │ ├── restorefilegroup.xml │ │ │ │ ├── restorehistory.xml │ │ │ │ ├── resumableindex.xml │ │ │ │ ├── schedule.xml │ │ │ │ ├── sdt.xml │ │ │ │ ├── sequence.xml │ │ │ │ ├── server.xml │ │ │ │ ├── servicemasterkey.xml │ │ │ │ ├── sharedschedule.xml │ │ │ │ ├── statistic.xml │ │ │ │ ├── synonym.xml │ │ │ │ ├── sysmessage.xml │ │ │ │ ├── table.xml │ │ │ │ ├── temp_table.xml │ │ │ │ ├── transaction.xml │ │ │ │ ├── trigger.xml │ │ │ │ ├── uddt.xml │ │ │ │ ├── udfcolumn.xml │ │ │ │ ├── user.xml │ │ │ │ ├── view.xml │ │ │ │ └── xmltype.xml │ │ ├── SqlScriptPublish │ │ │ ├── IScriptPublishOptions.cs │ │ │ ├── Microsoft.SqlServer.Management.SqlScriptPublish.csproj │ │ │ ├── SR.strings │ │ │ ├── SqlQueryHandler.cs │ │ │ ├── SqlScriptGenerator.cs │ │ │ ├── SqlScriptOptions.cs │ │ │ ├── SqlScriptOptionsSR.strings │ │ │ ├── SqlScriptPublishEnums.cs │ │ │ ├── SqlScriptPublishException.cs │ │ │ ├── SqlScriptPublishModel.cs │ │ │ ├── SqlScriptPublishModelTraceHelper.cs │ │ │ ├── SqlTransferOptions.cs │ │ │ └── TableSelectStatement.cs │ │ ├── XEvent │ │ │ ├── Microsoft.SqlServer.Management.XEvent.csproj │ │ │ ├── Server │ │ │ │ ├── ProviderConstants.cs │ │ │ │ ├── ServerEventProvider.cs │ │ │ │ ├── ServerSessionProvider.cs │ │ │ │ ├── ServerTargetProvider.cs │ │ │ │ ├── ServerXEStore.cs │ │ │ │ └── ServerXEStoreProvider.cs │ │ │ └── core │ │ │ │ ├── Action.cs │ │ │ │ ├── ActionCollection.cs │ │ │ │ ├── ActionInfo.cs │ │ │ │ ├── ActionInfoCollection.cs │ │ │ │ ├── Constants.cs │ │ │ │ ├── DataEventColumnInfo.cs │ │ │ │ ├── DataEventColumnInfoCollection.cs │ │ │ │ ├── Event.cs │ │ │ │ ├── EventCollection.cs │ │ │ │ ├── EventColumnInfo.cs │ │ │ │ ├── EventColumnInfoCollection.cs │ │ │ │ ├── EventField.cs │ │ │ │ ├── EventFieldCollection.cs │ │ │ │ ├── EventInfo.cs │ │ │ │ ├── EventInfoCollection.cs │ │ │ │ ├── ExceptionTemplates.strings │ │ │ │ ├── MapInfo.cs │ │ │ │ ├── MapInfoCollection.cs │ │ │ │ ├── MapValueInfo.cs │ │ │ │ ├── MapValueInfoCollection.cs │ │ │ │ ├── NetCoreHelpers.cs │ │ │ │ ├── Package.cs │ │ │ │ ├── PackageCollection.cs │ │ │ │ ├── PredCompareExpr.cs │ │ │ │ ├── PredCompareInfo.cs │ │ │ │ ├── PredCompareInfoCollection.cs │ │ │ │ ├── PredExpr.cs │ │ │ │ ├── PredFunctionExpr.cs │ │ │ │ ├── PredLogicalExpr.cs │ │ │ │ ├── PredOperand.cs │ │ │ │ ├── PredSourceInfo.cs │ │ │ │ ├── PredSourceInfoCollection.cs │ │ │ │ ├── PredValue.cs │ │ │ │ ├── Predicate.cs │ │ │ │ ├── ProviderInterfaces.cs │ │ │ │ ├── ReadOnlyEventColumnInfo.cs │ │ │ │ ├── ReadOnlyEventColumnInfoCollection.cs │ │ │ │ ├── Session.cs │ │ │ │ ├── SessionCollection.cs │ │ │ │ ├── SessionProviderBase.cs │ │ │ │ ├── Target.cs │ │ │ │ ├── TargetCollection.cs │ │ │ │ ├── TargetColumnInfo.cs │ │ │ │ ├── TargetColumnInfoCollection.cs │ │ │ │ ├── TargetField.cs │ │ │ │ ├── TargetFieldCollection.cs │ │ │ │ ├── TargetInfo.cs │ │ │ │ ├── TargetInfoCollection.cs │ │ │ │ ├── TraceHelper.cs │ │ │ │ ├── TypeInfo.cs │ │ │ │ ├── TypeInfoCollection.cs │ │ │ │ ├── XEObjectInfo.cs │ │ │ │ ├── XEObjectInfoCollection.cs │ │ │ │ ├── XEStore.cs │ │ │ │ ├── XEStoreObjectMetadata.cs │ │ │ │ ├── XEStoreSessionHelpers.cs │ │ │ │ ├── XEUtils.cs │ │ │ │ ├── XEventException.cs │ │ │ │ ├── XsdResource.Designer.cs │ │ │ │ ├── XsdResource.resx │ │ │ │ └── xeconfig.xsd │ │ ├── XEventDbScoped │ │ │ ├── Constants.cs │ │ │ ├── DatabaseEventProvider.cs │ │ │ ├── DatabaseSessionProvider.cs │ │ │ ├── DatabaseTargetProvider.cs │ │ │ ├── DatabaseXEStore.cs │ │ │ ├── DatabaseXEStoreProvider.cs │ │ │ ├── ExceptionTemplates.strings │ │ │ ├── Microsoft.SqlServer.Management.XEventDbScoped.csproj │ │ │ ├── NetCoreHelpers.cs │ │ │ ├── ProviderConstants.cs │ │ │ ├── XsdResource.Designer.cs │ │ │ └── XsdResource.resx │ │ ├── XEventDbScopedEnum │ │ │ ├── Microsoft.SqlServer.Management.XEventDbScopedEnum.csproj │ │ │ ├── XEStoreObject.cs │ │ │ ├── XEventObject.cs │ │ │ └── xml │ │ │ │ ├── Action.xml │ │ │ │ ├── ActionInfo.xml │ │ │ │ ├── DataEventColumnInfo.xml │ │ │ │ ├── Event.xml │ │ │ │ ├── EventColumnInfo.xml │ │ │ │ ├── EventField.xml │ │ │ │ ├── EventInfo.xml │ │ │ │ ├── MapInfo.xml │ │ │ │ ├── MapValueInfo.xml │ │ │ │ ├── Package.xml │ │ │ │ ├── PredCompareInfo.xml │ │ │ │ ├── PredSourceInfo.xml │ │ │ │ ├── ReadOnlyEventColumnInfo.xml │ │ │ │ ├── Session.xml │ │ │ │ ├── Target.xml │ │ │ │ ├── TargetColumnInfo.xml │ │ │ │ ├── TargetField.xml │ │ │ │ ├── TargetInfo.xml │ │ │ │ ├── TypeInfo.xml │ │ │ │ ├── XEStore.xml │ │ │ │ └── inc_urn.xml │ │ └── XEventEnum │ │ │ ├── Microsoft.SqlServer.Management.XEventEnum.csproj │ │ │ ├── XEventObject.cs │ │ │ └── xml │ │ │ ├── Action.xml │ │ │ ├── ActionInfo.xml │ │ │ ├── DataEventColumnInfo.xml │ │ │ ├── Event.xml │ │ │ ├── EventColumnInfo.xml │ │ │ ├── EventField.xml │ │ │ ├── EventInfo.xml │ │ │ ├── MapInfo.xml │ │ │ ├── MapValueInfo.xml │ │ │ ├── Package.xml │ │ │ ├── PredCompareInfo.xml │ │ │ ├── PredSourceInfo.xml │ │ │ ├── ReadOnlyEventColumnInfo.xml │ │ │ ├── Session.xml │ │ │ ├── Target.xml │ │ │ ├── TargetColumnInfo.xml │ │ │ ├── TargetField.xml │ │ │ ├── TargetInfo.xml │ │ │ ├── TypeInfo.xml │ │ │ ├── XEStore.xml │ │ │ └── inc_urn.xml │ └── SqlClrProvider │ │ ├── AssemblyInfo.cs │ │ ├── FxCopExclusions.cs │ │ ├── Microsoft.SqlServer.SqlClrProvider.csproj │ │ └── SqlClrProvider.cs └── dirs.proj ├── TestReferences.proj ├── UnitTest ├── Common │ └── UnitTestBase.cs ├── ConnectionInfo │ ├── ConnectionSettingsTests.cs │ ├── LocalizableTypeConverterTests.cs │ ├── Microsoft.SqlServer.Test.ConnectionInfoUnitTests.csproj │ ├── ServerConnectionTests.cs │ ├── ServerInformationTests.cs │ └── SqlConnectionInfoTests.cs ├── Directory.Build.props ├── Directory.Build.targets ├── Dmf │ ├── ExpressionTreeTests.cs │ ├── FacetTests.cs │ ├── Microsoft.SqlServer.Test.DmfUnitTests.csproj │ ├── PolicyStoreTests.cs │ └── TestData │ │ └── ExpressionTree_OperatorNodes.xml ├── Notebook │ ├── Microsoft.SqlServer.Test.SmoNotebookUnitTests.csproj │ ├── ModelTests.cs │ ├── NotebookFileWriterTests.cs │ └── SmoNotebookTests.cs ├── RegSvrEnum │ ├── Microsoft.SqlServer.Test.RegSvrEnumUnitTests.csproj │ ├── RegistrationInfoTests.cs │ └── UIConnectionInfoTests.cs ├── RegisteredServers │ ├── AdsTests.cs │ ├── Microsoft.SqlServer.Test.RegisteredServersUnitTests.csproj │ ├── RegisteredServersTests.cs │ ├── TstRegSrvr.xml │ └── sample.json ├── Sfc │ ├── FilterNodeTests.cs │ ├── Microsoft.SqlServer.Test.SfcUnitTests.csproj │ ├── SfcSerializerTests.cs │ └── UrnTests.cs ├── Smo │ ├── AffinityInfoTests.cs │ ├── BackupRestoreTests.cs │ ├── DataTypeTests.cs │ ├── DatabaseTests.cs │ ├── DdlParserTests.cs │ ├── FacetTests.cs │ ├── Microsoft.SqlServer.Test.SmoUnitTests.csproj │ ├── PathWrapperTests.cs │ ├── PermissionDecoderTests.cs │ ├── QueryIsolationTests.cs │ ├── ScriptStringBuilderTests.cs │ ├── SerializationTests.cs │ ├── ServerEventsTests.cs │ ├── ServerTests.cs │ ├── SingleFileWriterTEsts.cs │ ├── SqlObjectTests.cs │ └── SqlSmoObjectTests.cs ├── SqlScriptPublish │ ├── EnumTests.cs │ ├── Microsoft.SqlServer.Test.SqlScriptPublishTests.csproj │ ├── SqlScriptOptionsTests.cs │ └── SqlScriptPublishModelTests.cs ├── XEventDbScoped │ ├── ExceptionTests.cs │ ├── Microsoft.SqlServer.Test.XEventDbScopedUnitTests.csproj │ ├── PredValueUnitTest.cs │ ├── SessionUnitTest.cs │ └── TargetUnitTest.cs ├── dirs.proj └── unittest.runsettings ├── dirs.proj └── tests.proj /.gitattributes: -------------------------------------------------------------------------------- 1 | # Set the default behavior, in case people don't have core.autocrlf set. 2 | * text=auto 3 | 4 | # Use text conventions for commonly used text extensions. 5 | *.csv text 6 | *.ini text 7 | *.json text 8 | *.txt text 9 | *.xml text 10 | *.sql diff 11 | 12 | # Denote all files that are truly binary and should not be modified. 13 | *.dll binary 14 | *.exe binary 15 | *.gz binary 16 | *.ico binary 17 | *.jpg binary 18 | *.lib binary 19 | *.pdb binary 20 | *.pdf binary 21 | *.png binary 22 | *.wim binary 23 | *.zip binary 24 | -------------------------------------------------------------------------------- /.github/workflows/ToolsConnectionInfo.xml: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | unusedButRequired 6 | 7 | 8 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /.gitmodules: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/microsoft/sqlmanagementobjects/1b5ffd2300252ddc4103da2c792c999a5ac6193a/.gitmodules -------------------------------------------------------------------------------- /CODE_OF_CONDUCT.md: -------------------------------------------------------------------------------- 1 | # Microsoft Open Source Code of Conduct 2 | 3 | This project has adopted the [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/). 4 | 5 | Resources: 6 | 7 | - [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/) 8 | - [Microsoft Code of Conduct FAQ](https://opensource.microsoft.com/codeofconduct/faq/) 9 | - Contact [opencode@microsoft.com](mailto:opencode@microsoft.com) with questions or concerns 10 | -------------------------------------------------------------------------------- /Directory.Build.props: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 8 | $(MSBuildAllProjects);$(MSBuildThisFileFullPath) 9 | 10 | 13 | $(MSBuildThisFileDirectory.TrimEnd('\\')) 14 | net472 15 | 16 | 17 | -------------------------------------------------------------------------------- /Directory.Build.rsp: -------------------------------------------------------------------------------- 1 | /Restore 2 | /ConsoleLoggerParameters:Verbosity=Minimal;Summary 3 | /FileLoggerParameters:LogFile=msbuild.log;Verbosity=Diagnostic 4 | /MaxCPUCount 5 | /NodeReuse:false 6 | /Property:NuGetInteractive=true 7 | /BinaryLogger 8 | 9 | -------------------------------------------------------------------------------- /SmoBuild/AssemblyInfo.props: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | The SQL Server Management Objects (SMO) Framework is a set of objects designed for programmatic management of Microsoft SQL Server and Microsoft Azure SQL Database. 6 | 7 | Microsoft 8 | Microsoft Corporation 9 | Microsoft Sql Server 10 | © Microsoft Corporation. All rights reserved. 11 | 12 | true 13 | true 14 | 15 | 16 | -------------------------------------------------------------------------------- /SmoBuild/CSharp.NetCore.props: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /SmoBuild/CSharp.NetFx.props: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /SmoBuild/CSharp.NetStandard.props: -------------------------------------------------------------------------------- 1 | 2 | 3 | $(DefineConstants);NETSTANDARD2_0 4 | 5 | 6 | -------------------------------------------------------------------------------- /SmoBuild/DisableStrongName.ps1: -------------------------------------------------------------------------------- 1 | #This script is FOR TEST ONLY. It bypasses StrongName verification 2 | #for SQL assemblies, since they are delay signed the installer 3 | #will fail on non-signed builds unless we add the exceptions. 4 | 5 | 6 | #List of SQL public keys 7 | $publicKeys = @( 8 | "*,31bf3856ad364e35", 9 | "*,36e4ce08b8ecfb17", 10 | "*,89845dcd8080cc91", 11 | "*,b03f5f7f11d50a3a", 12 | "*,ae41e2615877eb90", 13 | "*,b77a5c561934e089") 14 | 15 | $publicKeys | % { 16 | New-Item -Path "HKLM:\SOFTWARE\Microsoft\StrongName\Verification\$_" -Force | Out-Null 17 | New-Item -Path "HKLM:\SOFTWARE\Wow6432Node\Microsoft\StrongName\Verification\$_" -Force | Out-Null 18 | } -------------------------------------------------------------------------------- /azurepipelines-coverage.yml: -------------------------------------------------------------------------------- 1 | coverage: 2 | status: #Code coverage status will be posted to pull requests based on targets defined below. 3 | comments: on #Off by default. When on, details about coverage for each file changed will be posted as a pull request comment. 4 | diff: #diff coverage is code coverage only for the lines changed in a pull request. 5 | target: 80% #set this to a desired %. Default is 70% 6 | -------------------------------------------------------------------------------- /dirs.proj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /docs/media/certsettings.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/microsoft/sqlmanagementobjects/1b5ffd2300252ddc4103da2c792c999a5ac6193a/docs/media/certsettings.png -------------------------------------------------------------------------------- /examples/GetSmoObject/GetSmoObject.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | net472 4 | Exe 5 | true 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /global.json: -------------------------------------------------------------------------------- 1 | { 2 | "sdk": { 3 | "version": "8.0.409", 4 | "rollForward": "latestMinor" 5 | }, 6 | "msbuild-sdks": { 7 | "Microsoft.Build.Traversal": "3.1.6" 8 | } 9 | } -------------------------------------------------------------------------------- /packages/.gitkeep: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/microsoft/sqlmanagementobjects/1b5ffd2300252ddc4103da2c792c999a5ac6193a/packages/.gitkeep -------------------------------------------------------------------------------- /src/Codegen/StringEnumerator.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | namespace Microsoft.SqlServer.Management.Sdk.Sfc 5 | { 6 | using System; 7 | 8 | // Fake definitions to keep the compiler happy - Codegen doesn't directly depend on these classes. Since it's an 9 | // internal tool, it would not be a big issue to work around any bugs on these, if found! 10 | class SfcObjectState{} 11 | class SfcInstance{} 12 | class SfcKey{} 13 | static class SfcUtility 14 | { 15 | //This is a fake method needed to work around the SFC.Util dependancies 16 | public static System.Reflection.Assembly LoadSqlCeAssembly(String name) { return null; } 17 | } 18 | 19 | 20 | } 21 | -------------------------------------------------------------------------------- /src/FunctionalTest/Framework/Helpers/ScriptSchemaObjectBaseHelpers.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | using System.Globalization; 5 | using Microsoft.SqlServer.Management.Smo; 6 | 7 | namespace Microsoft.SqlServer.Test.Manageability.Utils 8 | { 9 | /// 10 | /// Provides helper functionality for SMO ScriptSchemaObjectBase objects. 11 | /// 12 | public static class ScriptSchemaObjectBaseHelpers 13 | { 14 | /// 15 | /// Returns the schema-qualified name of the object without brackets. Use 16 | /// FullQualifiedName to get the schema-qualified name with brackets. 17 | /// 18 | /// 19 | /// 20 | public static string GetSchemaQualifiedNameNoBrackets(this ScriptSchemaObjectBase obj) 21 | { 22 | return string.Format("{0}.{1}", obj.Schema, obj.Name, CultureInfo.InvariantCulture); 23 | } 24 | } 25 | } -------------------------------------------------------------------------------- /src/FunctionalTest/Framework/Helpers/SqlTypeConverterHelpers.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | using System; 5 | using Microsoft.SqlServer.Management.Smo; 6 | 7 | namespace Microsoft.SqlServer.Test.Manageability.Utils.Helpers 8 | { 9 | /// 10 | /// Helper methods dealing with conversion of types 11 | /// 12 | public static class SqlTypeConverterHelpers 13 | { 14 | public static object ConvertToType(Type t, object obj) 15 | { 16 | if (t == typeof (DataType)) 17 | { 18 | return new DataType(DataType.SqlToEnum(obj.ToString())); 19 | } 20 | else if (t.IsEnum) 21 | { 22 | return obj is string ? Enum.Parse(t, (string)obj, true) : Enum.ToObject(t, obj); 23 | } 24 | else 25 | { 26 | return Convert.ChangeType(obj, t); 27 | } 28 | } 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /src/FunctionalTest/Framework/Helpers/TableExtensions.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | using Microsoft.SqlServer.Management.Smo; 5 | 6 | namespace Microsoft.SqlServer.Test.Manageability.Utils.Helpers 7 | { 8 | /// 9 | /// Extension methods for Table objects 10 | /// 11 | public static class TableExtensions 12 | { 13 | /// 14 | /// Returns true if the table is a ledger table or otherwise not able to be dropped. Safe to call for any server version. 15 | /// 16 | /// 17 | /// 18 | public static bool IsImmutable(this Table table) 19 | { 20 | return table.Replicated || table.IsSystemObject || (table.IsSupportedProperty(nameof(Table.LedgerType)) && table.LedgerType != LedgerTableType.None); 21 | } 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /src/FunctionalTest/Framework/PRVerification.runsettings: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 1 8 | true 9 | 10 | 11 | -------------------------------------------------------------------------------- /src/FunctionalTest/Framework/Scripts/ValidateTableDataRetention_DataRetentionPeriodOption.sql: -------------------------------------------------------------------------------- 1 | create table tableName_Month ([dbdatetime2] datetime2(7)) with (DATA_DELETION = ON ( FILTER_COLUMN = [dbdatetime2], RETENTION_PERIOD = 1 Month ) ) 2 | 3 | create table tableName_Week ([dbdatetime2] datetime2(7)) with (DATA_DELETION = ON ( FILTER_COLUMN = [dbdatetime2], RETENTION_PERIOD = 1 Week ) ) 4 | 5 | create table tableName_Day ([dbdatetime2] datetime2(7)) with (DATA_DELETION = ON ( FILTER_COLUMN = [dbdatetime2], RETENTION_PERIOD = 1 Day ) ) 6 | 7 | create table tableName_Year ([dbdatetime2] datetime2(7)) with (DATA_DELETION = ON ( FILTER_COLUMN = [dbdatetime2], RETENTION_PERIOD = 1 Year ) ) 8 | 9 | create table tableName_Infinite ([dbdatetime2] datetime2(7)) with (DATA_DELETION = ON ( FILTER_COLUMN = [dbdatetime2], RETENTION_PERIOD = INFINITE ) ) -------------------------------------------------------------------------------- /src/FunctionalTest/Framework/Sql2017Linux.runsettings: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /src/FunctionalTest/Framework/SqlVersion.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | using System; 5 | 6 | 7 | namespace Microsoft.SqlServer.Test.Manageability.Utils 8 | { 9 | [Flags] 10 | public enum SqlVersion 11 | { 12 | AzureSawaV1 = 1, 13 | AzureSterlingV12 = 2, 14 | Sql2005 = 4, 15 | Sql2008 = 8, 16 | Sql2008R2 = 16, 17 | Sql2012 = 32, 18 | Sql2012SP1 = 64, 19 | Sql2014 = 128, 20 | Sql2016 = 256, 21 | Sql2017 = 512, 22 | Sqlv150 = 1024 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /src/FunctionalTest/Framework/Sqlv150Linux.runsettings: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /src/FunctionalTest/Framework/Sqlv160Linux.runsettings: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /src/FunctionalTest/Framework/TestFramework/DisconnectedTestAttribute.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | using System; 5 | 6 | namespace Microsoft.SqlServer.Test.Manageability.Utils.TestFramework 7 | { 8 | /// 9 | /// Marks a test as being a "Disconnected" test, which means it will be run 10 | /// without making a server connection first. 11 | /// 12 | [AttributeUsage(AttributeTargets.Method, AllowMultiple = false)] 13 | public class DisconnectedTestAttribute : Attribute 14 | { 15 | public DisconnectedTestAttribute() 16 | { 17 | 18 | } 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /src/FunctionalTest/Framework/TestFramework/FabricWorkspaceDescriptor.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | using Microsoft.SqlServer.Test.Manageability.Utils.Helpers; 5 | 6 | namespace Microsoft.SqlServer.Test.Manageability.Utils.TestFramework 7 | { 8 | public class FabricWorkspaceDescriptor : TestDescriptor 9 | { 10 | public string Environment { get; set; } 11 | public string WorkspaceName { get; set; } 12 | public string DbNamePrefix { get; set; } 13 | 14 | public string CreateDatabase(string databaseName) => FabricDatabaseManager.CreateDatabase(WorkspaceName, databaseName); 15 | public void DropDatabase(string databaseName) => FabricDatabaseManager.DropDatabase(WorkspaceName, databaseName); 16 | 17 | } 18 | 19 | } 20 | -------------------------------------------------------------------------------- /src/FunctionalTest/Framework/TestFramework/IDatabaseHandler.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | using Microsoft.SqlServer.Management.Smo; 5 | using SMO = Microsoft.SqlServer.Management.Smo; 6 | 7 | namespace Microsoft.SqlServer.Test.Manageability.Utils.TestFramework 8 | { 9 | public interface IDatabaseHandler 10 | { 11 | SMO.Server ServerContext { get; set; } 12 | TestDescriptor TestDescriptor { get; set; } 13 | string DatabaseDisplayName { get; set; } 14 | Database HandleDatabaseCreation(DatabaseParameters dbParameters = null); 15 | void HandleDatabaseDrop(); 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /src/FunctionalTest/Framework/TestFramework/SqlRequiredFeatureAttribute.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | using System; 5 | 6 | namespace Microsoft.SqlServer.Test.Manageability.Utils.TestFramework 7 | { 8 | 9 | /// 10 | /// The attribute to describe the required features that must be enabled on the target servers in order to run the test 11 | /// 12 | [AttributeUsage(AttributeTargets.Class | AttributeTargets.Method)] 13 | public class SqlRequiredFeatureAttribute : Attribute 14 | { 15 | private SqlFeature[] _requiredFeatures; 16 | 17 | 18 | /// 19 | /// Constructor 20 | /// 21 | public SqlRequiredFeatureAttribute(params SqlFeature[] requiredFeatures) 22 | { 23 | _requiredFeatures = requiredFeatures; 24 | } 25 | 26 | public SqlFeature[] RequiredFeatures 27 | { 28 | get { return _requiredFeatures; } 29 | } 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /src/FunctionalTest/Framework/sqlv150.runsettings: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /src/FunctionalTest/Framework/sqlv160.runsettings: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /src/FunctionalTest/Framework/sqlv170.runsettings: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /src/FunctionalTest/Identity/AdoOidcResponse.cs: -------------------------------------------------------------------------------- 1 | using System.Text.Json.Serialization; 2 | 3 | namespace Microsoft.SqlServer.ADO.Identity 4 | { 5 | /// 6 | /// The response returned by the ADO OIDC endpoint 7 | /// 8 | internal class AdoOidcResponse 9 | { 10 | /// 11 | /// An idToken that can be used to authenticate as the service connection. 12 | /// 13 | [JsonPropertyName("oidcToken")] 14 | public string OidcToken { get; set; } 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /src/FunctionalTest/Smo/BackupRestore/LongFullBackupCleanup.sql: -------------------------------------------------------------------------------- 1 | USE [msdb] 2 | GO 3 | 4 | DECLARE @id1 INT, @id2 INT, @id3 INT, @id4 INT, @id5 INT, @id6 INT 5 | SET @id1 = (SELECT media_set_id FROM dbo.backupmediaset WHERE media_uuid='591E2543-77CD-4710-90EE-EFF499963810') 6 | SET @id2 = (SELECT media_set_id FROM dbo.backupmediaset WHERE media_uuid='CFE28E39-BECA-4B12-A9D4-71B4CD493B8C') 7 | SET @id3 = (SELECT media_set_id FROM dbo.backupmediaset WHERE media_uuid='422D0DAE-2FED-41C3-8E22-6B4884D70A85') 8 | SET @id4 = (SELECT media_set_id FROM dbo.backupmediaset WHERE media_uuid='84BC7B34-140A-437D-9348-B15B8B6036B4') 9 | SET @id5 = (SELECT media_set_id FROM dbo.backupmediaset WHERE media_uuid='13D05B2A-972D-49BD-8E8C-0E0ADB27FD18') 10 | 11 | DELETE FROM [dbo].[backupset] WHERE media_set_id IN (@id1, @id2, @id3, @id4, @id5) 12 | 13 | DELETE FROM [dbo].[backupmediafamily] WHERE media_set_id IN (@id1, @id2, @id3, @id4, @id5) 14 | 15 | DELETE FROM [dbo].[backupmediaset] WHERE media_set_id IN (@id1, @id2, @id3, @id4, @id5) 16 | GO -------------------------------------------------------------------------------- /src/FunctionalTest/Smo/BackupRestore/LongFullBackupPlan.sql: -------------------------------------------------------------------------------- 1 | USE [master] 2 | RESTORE DATABASE [Data] FROM URL = N'https://test.windows.net/sample/FULL/Data_FULL_2021_04_18_211501.bak' WITH FILE = 1, NORECOVERY, NOUNLOAD 3 | RESTORE LOG [Data] FROM URL = N'https://test.windows.net/sample/FULL/Data_LOG_2021_04_19_043000.trn' WITH FILE = 1, NOUNLOAD 4 | -------------------------------------------------------------------------------- /src/FunctionalTest/Smo/BackupRestore/NewerOutOfSequencePointInTimePlan.sql: -------------------------------------------------------------------------------- 1 | USE [master] 2 | RESTORE DATABASE [Data] FROM URL = N'https://test.windows.net/sample/FULL/Data_FULL_2021_03_24_201551.bak' WITH FILE = 1, NORECOVERY, NOUNLOAD 3 | RESTORE DATABASE [Data] FROM URL = N'https://test.windows.net/sample/FULL/Data_DIFF_2021_03_26_201508.bak' WITH FILE = 1, NORECOVERY, NOUNLOAD 4 | RESTORE LOG [Data] FROM URL = N'https://test.windows.net/sample/FULL/Data_LOG_2021_03_26_203010.trn' WITH FILE = 1, NORECOVERY, NOUNLOAD 5 | RESTORE LOG [Data] FROM URL = N'https://test.windows.net/sample/FULL/Data_LOG_2021_03_27_003008.trn' WITH FILE = 1, NOUNLOAD, STOPAT = N'2021-03-26T21:30:00' 6 | -------------------------------------------------------------------------------- /src/FunctionalTest/Smo/BackupRestore/OlderOutOfSequenceCleanup.sql: -------------------------------------------------------------------------------- 1 | USE [msdb] 2 | GO 3 | 4 | DECLARE @id1 INT, @id2 INT, @id3 INT, @id4 INT, @id5 INT, @id6 INT 5 | SET @id1 = (SELECT media_set_id FROM dbo.backupmediaset WHERE media_uuid='84BC7B34-140A-437D-9348-B15B8B6036B4') 6 | SET @id2 = (SELECT media_set_id FROM dbo.backupmediaset WHERE media_uuid='591E2543-77CD-4710-90EE-EFF499963810') 7 | SET @id3 = (SELECT media_set_id FROM dbo.backupmediaset WHERE media_uuid='CFE28E39-BECA-4B12-A9D4-71B4CD493B8C') 8 | SET @id4 = (SELECT media_set_id FROM dbo.backupmediaset WHERE media_uuid='D81AA204-995E-43CF-AE3B-54A2AD95ACEA') 9 | SET @id5 = (SELECT media_set_id FROM dbo.backupmediaset WHERE media_uuid='422D0DAE-2FED-41C3-8E22-6B4884D70A85') 10 | 11 | DELETE FROM [dbo].[backupset] WHERE media_set_id IN (@id1, @id2, @id3, @id4, @id5) 12 | 13 | DELETE FROM [dbo].[backupmediafamily] WHERE media_set_id IN (@id1, @id2, @id3, @id4, @id5) 14 | 15 | DELETE FROM [dbo].[backupmediaset] WHERE media_set_id IN (@id1, @id2, @id3, @id4, @id5) 16 | GO -------------------------------------------------------------------------------- /src/FunctionalTest/Smo/BackupRestore/OlderOutOfSequencePointInTimePlan.sql: -------------------------------------------------------------------------------- 1 | USE [master] 2 | RESTORE DATABASE [Data] FROM URL = N'https://test.windows.net/sample/FULL/Data_FULL_2021_04_14_201501.bak' WITH FILE = 1, NORECOVERY, NOUNLOAD 3 | RESTORE DATABASE [Data] FROM URL = N'https://test.windows.net/sample/FULL/Data_DIFF_2021_04_18_201500.bak' WITH FILE = 1, NORECOVERY, NOUNLOAD 4 | RESTORE LOG [Data] FROM URL = N'https://test.windows.net/sample/FULL/Data_LOG_2021_04_18_203000.trn' WITH FILE = 1, NORECOVERY, NOUNLOAD 5 | RESTORE LOG [Data] FROM URL = N'https://test.windows.net/sample/FULL/Data_LOG_2021_04_19_003000.trn' WITH FILE = 1, NOUNLOAD, STOPAT = N'2021-04-19T00:15:00' 6 | -------------------------------------------------------------------------------- /src/FunctionalTest/Smo/ScriptingTests/Data/qatest/bands.dat: -------------------------------------------------------------------------------- 1 | 1|AAAAA|LBC|500.0|14| 2 | 2|BBBBB|MSP|350.0|29| 3 | 3|CCCCC|ABC|550.0|67| 4 | 4|DDDDD|DEF|120.0|5| 5 | 5|EEEEE|GHI|412.5|41| 6 | 6|FFFFF|JKL|0.32000000000000001|0| -------------------------------------------------------------------------------- /src/FunctionalTest/Smo/ScriptingTests/Scripts/DependencyOrderScriptingDb.sql: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/microsoft/sqlmanagementobjects/1b5ffd2300252ddc4103da2c792c999a5ac6193a/src/FunctionalTest/Smo/ScriptingTests/Scripts/DependencyOrderScriptingDb.sql -------------------------------------------------------------------------------- /src/FunctionalTest/Smo/ScriptingTests/Scripts/ExternalLibrary_SmoTestSuite_Setup.sql: -------------------------------------------------------------------------------- 1 | --======================================================= 2 | --This file contains statements to run that are valid 3 | --for any On-Prem SQL Server version 14.0 (2017) and above 4 | --======================================================= 5 | 6 | CREATE EXTERNAL LIBRARY lazyeval FROM (content = 0xa0000000) WITH (language = 'R'); 7 | GO 8 | -------------------------------------------------------------------------------- /src/FunctionalTest/Smo/ScriptingTests/Scripts/PartitionedTable.sql: -------------------------------------------------------------------------------- 1 | CREATE PARTITION FUNCTION [AgePartFunc](int) AS RANGE RIGHT FOR VALUES (18) 2 | GO 3 | 4 | CREATE PARTITION SCHEME [AgePartScheme] AS PARTITION [AgePartFunc] TO ([PRIMARY], [PRIMARY]) 5 | GO 6 | 7 | CREATE TABLE [dbo].[Customers] 8 | ( 9 | id int identity, 10 | name varchar(255), 11 | age int 12 | constraint PK_CUSTOMERS 13 | primary key (id, age) 14 | ) ON AgePartScheme (age); 15 | GO -------------------------------------------------------------------------------- /src/FunctionalTest/Smo/ScriptingTests/ValidateTableDataRetention_DataRetentionPeriodOption.sql: -------------------------------------------------------------------------------- 1 | create table tableName_Month ([dbdatetime2] datetime2(7)) with (DATA_DELETION = ON ( FILTER_COLUMN = [dbdatetime2], RETENTION_PERIOD = 1 Month ) ) 2 | 3 | create table tableName_Week ([dbdatetime2] datetime2(7)) with (DATA_DELETION = ON ( FILTER_COLUMN = [dbdatetime2], RETENTION_PERIOD = 1 Week ) ) 4 | 5 | create table tableName_Day ([dbdatetime2] datetime2(7)) with (DATA_DELETION = ON ( FILTER_COLUMN = [dbdatetime2], RETENTION_PERIOD = 1 Day ) ) 6 | 7 | create table tableName_Year ([dbdatetime2] datetime2(7)) with (DATA_DELETION = ON ( FILTER_COLUMN = [dbdatetime2], RETENTION_PERIOD = 1 Year ) ) 8 | 9 | create table tableName_Infinite ([dbdatetime2] datetime2(7)) with (DATA_DELETION = ON ( FILTER_COLUMN = [dbdatetime2], RETENTION_PERIOD = INFINITE ) ) -------------------------------------------------------------------------------- /src/FunctionalTest/Smo/WMI/ServerEventsTests.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | namespace Microsoft.SqlServer.Test.Smo.WMI 5 | { 6 | /// 7 | /// Tests for Server.Events and related objects 8 | /// Requires running the tests under an account that has WMI 9 | /// 10 | public class ServerEventsTests 11 | { 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /src/FunctionalTest/Smo/XEvent/PredValueUnitTest.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | using Microsoft.SqlServer.Management.XEvent; 5 | using Microsoft.VisualStudio.TestTools.UnitTesting; 6 | 7 | namespace Microsoft.SqlServer.Management.XEventDbScoped.UnitTests 8 | { 9 | /// 10 | /// Summary description for PredValueUnitTest 11 | /// 12 | [TestClass] 13 | public class PredValueUnitTest 14 | { 15 | /// 16 | /// Tests the string constructor. 17 | /// 18 | [TestMethod] 19 | [TestCategory("Unit")] 20 | public void TestStringConstructor() 21 | { 22 | PredValue value = new PredValue("abcdefg"); 23 | Assert.AreEqual("abcdefg", value.ToString()); 24 | value = new PredValue(""); 25 | Assert.AreEqual("", value.ToString()); 26 | } 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /src/FunctionalTest/Smo/XEvent/Util.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | 5 | namespace Microsoft.SqlServer.Management.XEventDbScoped.UnitTests 6 | { 7 | internal class XEUtil 8 | { 9 | internal static string Package0PackageName = "package0"; 10 | internal static string SqlServerPackageName = "sqlserver"; 11 | internal static string SqlosPackageName = "sqlos"; 12 | internal static string TypeTypeName = "type"; 13 | internal static string EventTypeName = "event"; 14 | internal static string TargetTypeName = "target"; 15 | internal static string ActionTypeName = "action"; 16 | internal static string PredCompareTypeName = "pred_compare"; 17 | internal static string PredSourceTypeName = "pred_source"; 18 | internal static string MapTypeName = "map"; 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /src/FunctionalTest/dirs.proj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /src/Microsoft/Data/Tools.Sql.BatchParser/BatchParserAction.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | namespace Microsoft.Data.Tools.Sql.BatchParser 5 | { 6 | internal enum BatchParserAction 7 | { 8 | Continue = 0, 9 | Abort = 1 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /src/Microsoft/Data/Tools.Sql.BatchParser/ErrorCode.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | namespace Microsoft.Data.Tools.Sql.BatchParser 5 | { 6 | enum ErrorCode 7 | { 8 | ErrorCodeBase = 0, 9 | 10 | Success = ErrorCodeBase, 11 | // Lexer error codes 12 | UnsupportedCommand = ErrorCodeBase + 1, 13 | UnrecognizedToken = ErrorCodeBase + 2, 14 | StringNotTerminated = ErrorCodeBase + 3, 15 | CommentNotTerminated = ErrorCodeBase + 4, 16 | 17 | // Parser error codes 18 | InvalidVariableName = ErrorCodeBase + 6, 19 | InvalidNumber = ErrorCodeBase + 7, 20 | TokenExpected = ErrorCodeBase + 8, 21 | Aborted = ErrorCodeBase + 9, 22 | CircularReference = ErrorCodeBase + 10, 23 | VariableNotDefined = ErrorCodeBase + 11, 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /src/Microsoft/Data/Tools.Sql.BatchParser/ICommandHandler.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | 5 | using System.IO; 6 | 7 | namespace Microsoft.Data.Tools.Sql.BatchParser 8 | { 9 | internal interface ICommandHandler 10 | { 11 | BatchParserAction Go(TextBlock batch, int repeatCount); 12 | BatchParserAction OnError(Token token, OnErrorAction action); 13 | BatchParserAction Include(TextBlock filename, out TextReader stream, out string newFilename); 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /src/Microsoft/Data/Tools.Sql.BatchParser/IVariableResolver.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | namespace Microsoft.Data.Tools.Sql.BatchParser 5 | { 6 | internal interface IVariableResolver 7 | { 8 | string GetVariable(PositionStruct pos, string name); 9 | void SetVariable(PositionStruct pos, string name, string value); 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /src/Microsoft/Data/Tools.Sql.BatchParser/LexerTokenType.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | namespace Microsoft.Data.Tools.Sql.BatchParser 5 | { 6 | internal enum LexerTokenType 7 | { 8 | None, 9 | Text, 10 | TextVerbatim, 11 | Whitespace, 12 | NewLine, 13 | String, 14 | Eof, 15 | Error, 16 | Comment, 17 | 18 | // batch commands 19 | Go, 20 | Reset, 21 | Ed, 22 | Execute, 23 | Quit, 24 | Exit, 25 | Include, 26 | Serverlist, 27 | Setvar, 28 | List, 29 | ErrorCommand, 30 | Out, 31 | Perftrace, 32 | Connect, 33 | OnError, 34 | Help, 35 | Xml, 36 | ListVar, 37 | } 38 | } 39 | -------------------------------------------------------------------------------- /src/Microsoft/Data/Tools.Sql.BatchParser/Microsoft.Data.Tools.Sql.BatchParser.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | $(MSBuildAllProjects);$(MSBuildThisFileFullPath) 4 | $(TargetFrameworks) 5 | false 6 | false 7 | Microsoft.Data.Tools.Sql.BatchParser 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /src/Microsoft/Data/Tools.Sql.BatchParser/OnErrorAction.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | namespace Microsoft.Data.Tools.Sql.BatchParser 5 | { 6 | internal enum OnErrorAction 7 | { 8 | Ignore = 0, 9 | Exit = 1, 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /src/Microsoft/Data/Tools.Sql.BatchParser/PositionStruct.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | namespace Microsoft.Data.Tools.Sql.BatchParser 5 | { 6 | internal struct PositionStruct 7 | { 8 | private int _line; 9 | private int _column; 10 | private int _offset; 11 | private string _filename; 12 | 13 | public PositionStruct(int line, int column, int offset, string filename) 14 | { 15 | _line = line; 16 | _column = column; 17 | _offset = offset; 18 | _filename = filename; 19 | } 20 | 21 | public int Line { get { return _line; } } 22 | public int Column { get { return _column; } } 23 | public int Offset { get { return _offset; } } 24 | public string Filename { get { return _filename; } } 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /src/Microsoft/Data/Tools.Sql.BatchParser/TextRuleFlags.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | using System; 5 | 6 | namespace Microsoft.Data.Tools.Sql.BatchParser 7 | { 8 | [Flags] 9 | internal enum TextRuleFlags 10 | { 11 | ReportWhitespace = 1, 12 | RecognizeDoubleQuotedString = 2, 13 | RecognizeSingleQuotedString = 4, 14 | RecognizeLineComment = 8, 15 | RecognizeBlockComment = 16, 16 | RecognizeBrace = 32, 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /src/Microsoft/Data/Tools.Sql.BatchParser/Token.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | namespace Microsoft.Data.Tools.Sql.BatchParser 5 | { 6 | internal sealed class Token 7 | { 8 | internal Token(LexerTokenType tokenType, PositionStruct begin, PositionStruct end, string text, string filename) 9 | { 10 | TokenType = tokenType; 11 | Begin = begin; 12 | End = end; 13 | Text = text; 14 | Filename = filename; 15 | } 16 | 17 | public string Filename { get; private set; } 18 | 19 | public PositionStruct Begin { get; private set; } 20 | 21 | public PositionStruct End { get; private set; } 22 | 23 | public string Text { get; private set; } 24 | 25 | public LexerTokenType TokenType { get; private set; } 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /src/Microsoft/Data/Tools.Sql.BatchParser/VariableReference.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | namespace Microsoft.Data.Tools.Sql.BatchParser 5 | { 6 | internal sealed class VariableReference 7 | { 8 | public VariableReference(int start, int length, string variableName) 9 | { 10 | Start = start; 11 | Length = length; 12 | VariableName = variableName; 13 | VariableValue = null; 14 | } 15 | 16 | public int Length { get; private set; } 17 | 18 | public int Start { get; private set; } 19 | 20 | public string VariableName { get; private set; } 21 | 22 | public string VariableValue { get; internal set; } 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /src/Microsoft/Directory.Build.targets: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | $(BaseOutputPath)\Documentation\$(TargetFramework)\$(AssemblyName).xml 6 | 8 | $(NoWarn);1591 9 | 10 | 11 | 12 | false 13 | 14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/ConnectionInfo/App.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/ConnectionInfo/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | 5 | using System.Security; 6 | 7 | // make code access security compatible with Netfx 2.0 8 | [assembly: SecurityRules(SecurityRuleSet.Level1)] -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/ConnectionInfo/DatabaseEngineTypeExtensionClass.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | 5 | namespace Microsoft.SqlServer.Management.Common 6 | { 7 | /// 8 | /// Helper methods for enum DatabaseEngineType 9 | /// 10 | internal static class DatabaseEngineTypeExtension 11 | { 12 | /// 13 | /// This method always returns false 14 | /// Once we fix all the dependents to remove matrix related code, we shall remove this class 15 | /// 16 | /// 17 | /// 18 | //[Obsolete("Matrix code is currently being removed. Please remove the code that calls this method")] 19 | internal static bool IsMatrix(DatabaseEngineType databaseEngineType) 20 | { 21 | return false; 22 | } 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/ConnectionInfo/SqlContext.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | #if NETCOREAPP 5 | 6 | namespace Microsoft.SqlServer.Server 7 | { 8 | 9 | 10 | /// 11 | ///Implementation of SqlContext.IsAvailable for use with the dotnetcore framework since SqlContext.IsAvailable isn't available on .NetCore 12 | /// 13 | public class SqlContext 14 | { 15 | public static bool IsAvailable = false; 16 | 17 | public static SqlPipe Pipe { get; } 18 | } 19 | 20 | public class SqlPipe 21 | { 22 | public void Send(string message) 23 | { } 24 | } 25 | } 26 | #endif -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Dmf.Common/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | #if APTCA_ENABLED 5 | [assembly: System.Security.AllowPartiallyTrustedCallers] 6 | // make code access security compatible with Netfx 2.0 7 | [assembly: System.Security.SecurityRules(System.Security.SecurityRuleSet.Level1)] 8 | #endif -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Dmf.Common/DmfConstants.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | namespace Microsoft.SqlServer.Management.Dmf 5 | { 6 | /// 7 | /// Constants for use in DMF 8 | /// 9 | public static class DmfConstants 10 | { 11 | /// 12 | /// SqlServer Public Key 13 | /// 14 | public const string MICROSOFT_SQLSERVER_PUBLIC_KEY = "0024000004800000940000000602000000240000525341310004000001000100272736ad6e5f9586bac2d531eabc3acc666c2f8ec879fa94f8f7b0327d2ff2ed523448f83c3d5c5dd2dfc7bc99c5286b2c125117bf5cbe242b9d41750732b2bdffe649c6efb8e5526d526fdd130095ecdb7bf210809c6cdad8824faa9ac0310ac3cba2aa0523567b2dfa7fe250b30facbd62d4ec99b94ac47c7d3b28f1f6e4c8"; 15 | } 16 | 17 | } -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Dmf.Common/Microsoft.SqlServer.Dmf.Common.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | $(TargetFrameworks) 4 | $(MSBuildAllProjects);$(MSBuildThisFileFullPath) 5 | false 6 | Microsoft.SqlServer.Management.Dmf.Common 7 | 8 | 9 | $(DefineConstants);APTCA_ENABLED 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Dmf/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | #if APTCA_ENABLED 5 | [assembly: System.Security.AllowPartiallyTrustedCallers] 6 | // make code access security compatible with Netfx 2.0 7 | [assembly: System.Security.SecurityRules(System.Security.SecurityRuleSet.Level1)] 8 | #endif 9 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Dmf/FacetInfoCollection.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | 5 | 6 | using System.Collections.Generic; 7 | using System.Collections.ObjectModel; 8 | using Microsoft.SqlServer.Management.Sdk.Sfc; 9 | 10 | namespace Microsoft.SqlServer.Management.Dmf 11 | { 12 | /// 13 | /// This is the collection for FacetInfo. 14 | /// 15 | #if APTCA_ENABLED 16 | [System.Security.Permissions.StrongNameIdentityPermission(System.Security.Permissions.SecurityAction.LinkDemand, PublicKey = DmfConstants.MICROSOFT_SQLSERVER_PUBLIC_KEY)] 17 | #endif 18 | public sealed class FacetInfoCollection : KeyedCollection 19 | { 20 | /// 21 | /// 22 | /// 23 | protected override string GetKeyForItem(FacetInfo item) 24 | { 25 | return item.Name; 26 | } 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Dmf/FacetProperties.strings: -------------------------------------------------------------------------------- 1 | 2 | 3 | OffByDefault_AdHocDistributedQueriesEnabled = Ad-hoc Distributed Queries Enabled 4 | OffByDefault_DatabaseMailEnabled = Database Mail Enabled 5 | ConditionExpressionOnObject(string policy) = {0} ConditionExpression 6 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Dmf/LocalizableResources.strings: -------------------------------------------------------------------------------- 1 | ######### Begin PolicyStore 2 | 3 | PolicyStore_Name=PolicyStore 4 | PolicyStore_Desc=Exposes properties of the PolicyStore object. 5 | 6 | PolicyStore_EnabledName=Enabled 7 | PolicyStore_EnabledDesc=Specifies whether Policy Management is enabled. 8 | 9 | PolicyStore_HistoryRetentionInDaysName=HistoryRetentionInDays 10 | PolicyStore_HistoryRetentionInDaysDesc=Specifies the number of days that policy evaluation history should be retained. If this value is 0, the history will not be automatically removed. 11 | 12 | PolicyStore_LogOnSuccessName=LogOnSuccess 13 | PolicyStore_LogOnSuccessDesc=Specifies whether Policy Management logs successful policy evaluations. When this value is false, only failed policy evaluations are logged. 14 | 15 | ####### End PolicyStore 16 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/HadrData/AGListenerNetworkMode.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | namespace Microsoft.SqlServer.Management.HadrData 5 | { 6 | /// 7 | /// AGListenerNetworkMode 8 | /// 9 | public enum AGListenerNetworkMode 10 | { 11 | DHCP = 0, 12 | StaticIP = 1, 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/HadrData/AvailabilityGroupListenerSubnet.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | namespace Microsoft.SqlServer.Management.HadrData 5 | { 6 | /// 7 | /// Class that stores information about an availability group subnet 8 | /// 9 | public class AvailabilityGroupListenerSubnet 10 | { 11 | /// 12 | /// Checks if subnet is Dhcp 13 | /// 14 | public bool IsDHCP { get; set; } 15 | 16 | /// 17 | /// The Subnet ip address 18 | /// 19 | public string SubnetIP { get; set; } 20 | 21 | /// 22 | /// The subnet mask 23 | /// 24 | public string SubnetMask { get; set; } 25 | 26 | /// 27 | /// The ip address 28 | /// 29 | public string IPAddress { get; set; } 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/HadrData/AvailabilityGroupReplicaCollection.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | using System.Collections.Generic; 5 | 6 | namespace Microsoft.SqlServer.Management.HadrData 7 | { 8 | /// 9 | /// The Replica Collection Data contains a BindingList of AvailabilityGroupReplica 10 | /// 11 | internal class AvailabilityGroupReplicaCollection : SortableBindingList 12 | { 13 | public AvailabilityGroupReplicaCollection() 14 | { 15 | } 16 | 17 | public AvailabilityGroupReplicaCollection(IList replicaList) 18 | : base(replicaList) 19 | { 20 | } 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/HadrData/AvailabilityObjectState.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | namespace Microsoft.SqlServer.Management.HadrData 5 | { 6 | /// 7 | /// Enum which tells the state of the AvailabilityGroup object 8 | /// 9 | public enum AvailabilityObjectState 10 | { 11 | /// 12 | /// The object is in unknown state 13 | /// 14 | Unknown = 0, 15 | 16 | /// 17 | /// The object is being created on server 18 | /// 19 | Creating = 1, 20 | 21 | /// 22 | /// The object already exists on server 23 | /// 24 | Existing = 2 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/HadrData/CollectionsExtensionMethods.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | using System; 5 | using System.Collections.Generic; 6 | 7 | namespace Microsoft.SqlServer.Management.HadrData 8 | { 9 | /// 10 | /// Collection Extension Method Class 11 | /// 12 | internal static class CollectionsExtensionMethods 13 | { 14 | public static void AddRange(this ICollection target, IEnumerable items) 15 | { 16 | 17 | if (items == null) 18 | { 19 | throw new ArgumentNullException("items"); 20 | } 21 | 22 | foreach (T item in items) 23 | { 24 | target.Add(item); 25 | } 26 | } 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/HadrData/DataSynchronizationOption.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | using Microsoft.SqlServer.Management.Sdk.Sfc; 5 | 6 | namespace Microsoft.SqlServer.Management.HadrData 7 | { 8 | /// 9 | /// The Database SychronizationOption for an AG 10 | /// 11 | [LocalizedPropertyResources("Microsoft.SqlServer.Management.HadrData.Resource")] 12 | public enum DataSynchronizationOption 13 | { 14 | [DisplayNameKey("FullDataSync")] 15 | Full = 0, 16 | [DisplayNameKey("JoinOnlyDataSync")] 17 | JoinOnly, 18 | [DisplayNameKey("ManualDataSync")] 19 | Manual, 20 | [DisplayNameKey("AutomaticSeedingDataSync")] 21 | AutomaticSeeding, 22 | }; 23 | } 24 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/HadrData/FailoverCategory.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | namespace Microsoft.SqlServer.Management.HadrData 5 | { 6 | /// 7 | /// Failover Category Enum 8 | /// 9 | public enum FailoverCategory 10 | { 11 | /// 12 | /// Failover with data loss 13 | /// 14 | FailoverWithDataLoss = 0, 15 | 16 | /// 17 | /// Failover without data loss 18 | /// 19 | FailoverWithoutDataLoss = 1, 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/HadrData/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | using System.Runtime.InteropServices; 4 | 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | [assembly: AssemblyTitle("HadrData")] 9 | [assembly: AssemblyDescription("")] 10 | [assembly: AssemblyConfiguration("")] 11 | [assembly: AssemblyCulture("")] 12 | [assembly: Guid("B5744F2B-F600-4829-A5AE-FCAAF45A62EA")] -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/HadrData/ReplicaRole.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | using Microsoft.SqlServer.Management.Sdk.Sfc; 5 | 6 | namespace Microsoft.SqlServer.Management.HadrData 7 | { 8 | 9 | [LocalizedPropertyResources("Microsoft.SqlServer.Management.HadrData.Resource")] 10 | public enum ReplicaRole 11 | { 12 | /// 13 | /// Replica is in primary role 14 | /// 15 | [DisplayNameKey("Primary")] 16 | Primary = 0, 17 | 18 | /// 19 | /// Replica is in secondary role 20 | /// 21 | [DisplayNameKey("Secondary")] 22 | Secondary = 1 23 | }; 24 | } 25 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/HadrModel/AvailabilityModeIncompatibleException.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | using System.Globalization; 5 | 6 | namespace Microsoft.SqlServer.Management.HadrModel 7 | { 8 | /// 9 | /// This exception is thrown when one of the secondary replicas 10 | /// has an availabilitymode of Synchronous Commit, when the primary's 11 | /// availabilitymode is not Synchronous. 12 | /// 13 | public class AvailabilityModeIncompatibleException : HadrValidationErrorException 14 | { 15 | /// 16 | /// Constructor 17 | /// 18 | public AvailabilityModeIncompatibleException() 19 | : base(string.Format(CultureInfo.InvariantCulture, Resource.AvailabilityModeCompatibilityWarning)) 20 | { 21 | } 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/HadrModel/ClusterNodeState.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | namespace Microsoft.SqlServer.Management.HadrModel 5 | { 6 | /// 7 | /// Matching MSCluster_Node definition 8 | /// http://msdn.microsoft.com/en-us/library/aa371446(v=vs.85).aspx 9 | /// 10 | public enum ClusterNodeState 11 | { 12 | /// 13 | /// unknown state 14 | /// 15 | Unknown = -1, 16 | 17 | /// 18 | /// node is up 19 | /// 20 | Up = 0, 21 | 22 | /// 23 | /// node is down 24 | /// 25 | Down = 1, 26 | 27 | /// 28 | /// node paused 29 | /// 30 | Paused = 2, 31 | 32 | /// 33 | /// node joining 34 | /// 35 | Joining = 3 36 | } 37 | } 38 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/HadrModel/EncryptionAlgorithmMismatchException.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | using System.Globalization; 5 | 6 | namespace Microsoft.SqlServer.Management.HadrModel 7 | { 8 | /// 9 | /// EncryptionAlgorithmMismatchException is thrown if the encryption algorithm of any replica is does not match the others in the Availability Group 10 | /// 11 | public class EncryptionAlgorithmMismatchException : HadrValidationErrorException 12 | { 13 | /// 14 | /// Constructor 15 | /// 16 | /// The replicas 17 | public EncryptionAlgorithmMismatchException(string replicasString) 18 | : base(string.Format(CultureInfo.InvariantCulture, Resource.EncryptionMismatchException, replicasString)) 19 | { 20 | } 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/HadrModel/EncryptionMismatchException.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | using System.Globalization; 5 | 6 | namespace Microsoft.SqlServer.Management.HadrModel 7 | { 8 | /// 9 | /// EncryptionMismatchException is thrown if the encryption of any replica is does not match the others in the Availability Group 10 | /// 11 | public class EncryptionMismatchException : HadrTaskBaseException 12 | { 13 | /// 14 | /// Constructor 15 | /// 16 | /// The replicas 17 | public EncryptionMismatchException(string replicasString) 18 | : base(string.Format(CultureInfo.InvariantCulture, Resource.EncryptionMismatchException, replicasString)) 19 | { 20 | } 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/HadrModel/FeatureInstallationState.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | namespace Microsoft.SqlServer.Management.HadrModel 5 | { 6 | /// 7 | /// Used by WHIHelper for the Feature Installation State 8 | /// 9 | public enum FeatureInstallationState 10 | { 11 | /// 12 | /// unkown state 13 | /// 14 | Unknown, 15 | 16 | /// 17 | /// feature installed 18 | /// 19 | Installed, 20 | 21 | /// 22 | /// not installed 23 | /// 24 | NotInstalled 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/HadrModel/GroupUserMembership.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | namespace Microsoft.SqlServer.Management.HadrModel 5 | { 6 | /// 7 | /// Used by WHIHelper for the Group User Membership 8 | /// 9 | public enum GroupUserMembership 10 | { 11 | /// 12 | /// unkownn membership 13 | /// 14 | Unknown, 15 | 16 | /// 17 | /// is a member 18 | /// 19 | Member, 20 | 21 | /// 22 | /// not a member 23 | /// 24 | NonMember 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/HadrModel/HadrTaskBaseException.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | using System; 5 | 6 | namespace Microsoft.SqlServer.Management.HadrModel 7 | { 8 | /// 9 | /// The Base Validation Exception For HADRTask Model 10 | /// 11 | public class HadrTaskBaseException : Exception 12 | { 13 | /// 14 | /// Standard Exception with Message 15 | /// 16 | /// 17 | public HadrTaskBaseException(string message) 18 | : base(message) 19 | { 20 | } 21 | 22 | /// 23 | /// Exception with Message and Inner Exception 24 | /// 25 | /// 26 | /// 27 | public HadrTaskBaseException(string message, Exception inner) 28 | : base(message, inner) 29 | { 30 | } 31 | } 32 | } -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/HadrModel/IScriptableTask.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | using System.Collections.Generic; 5 | using Microsoft.SqlServer.Management.Common; 6 | 7 | namespace Microsoft.SqlServer.Management.HadrModel 8 | { 9 | /// 10 | /// Interface to be implemented by tasks that support scripting. 11 | /// 12 | /// Scripting is implemented by changing the ConnectionMode of 13 | /// the connection to CaptureSql instead of ExecuteSql. 14 | /// 15 | /// For this to be done by the UI, the task needs to expose the 16 | /// connections on which it does work. 17 | /// 18 | public interface IScriptableTask 19 | { 20 | /// 21 | /// The connections on which the task will do work 22 | /// 23 | List ScriptingConnections 24 | { 25 | get; 26 | } 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/HadrModel/ITasksProvider.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | using System.Collections.Generic; 5 | 6 | namespace Microsoft.SqlServer.Management.HadrModel 7 | { 8 | /// 9 | /// Tasks providers interface. A scenario list of tasks to complete 10 | /// 11 | public interface ITasksProvider 12 | { 13 | /// 14 | /// Get the list of tasks the provider supports 15 | /// 16 | /// 17 | List Tasks(); 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/HadrModel/IValidatorProvider.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | using System.Collections.Generic; 5 | 6 | namespace Microsoft.SqlServer.Management.HadrModel 7 | { 8 | /// 9 | /// The interface represents the base validator provider class which consists of a list of Validator 10 | /// The provider will provide a sequence of validation rules with certain input parameter, 11 | /// eg. a list of WAVM validator with WAVM configuration data object or a WA subscription info validator with WA subscription data 12 | /// 13 | public interface IValidatorProvider 14 | { 15 | /// 16 | /// List of valiatior rules to ensure all requirements for the validator operation(s) are meet. 17 | /// 18 | List Validators(); 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/HadrModel/JoinDatabaseToAvailabilityGroupException.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | using System; 5 | 6 | namespace Microsoft.SqlServer.Management.HadrModel 7 | { 8 | /// 9 | /// This exception is thrown when database fails to join the availability group 10 | /// 11 | public class JoinDatabaseToAvailabilityGroupException : HadrTaskBaseException 12 | { 13 | /// 14 | /// Constructor 15 | /// 16 | /// Inner exception 17 | public JoinDatabaseToAvailabilityGroupException(Exception inner) 18 | : base(Resource.JoinAvailabilityGroupError, inner) 19 | { 20 | } 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/HadrModel/ListenerConfigurationException.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | namespace Microsoft.SqlServer.Management.HadrModel 5 | { 6 | /// 7 | /// This exception is thrown when there is no Listener defined for the AG. 8 | /// 9 | public class ListenerConfigurationException : HadrValidationErrorException 10 | { 11 | /// 12 | /// Constructor 13 | /// 14 | public ListenerConfigurationException() 15 | : base(Resource.ListenerConfigurationWarning) 16 | { 17 | } 18 | } 19 | } -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/HadrModel/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | using System.Reflection; 5 | using System.Runtime.InteropServices; 6 | 7 | // General Information about an assembly is controlled through the following 8 | // set of attributes. Change these attribute values to modify the information 9 | // associated with an assembly. 10 | [assembly: AssemblyCulture("")] 11 | [assembly: Guid("7437F4D8-3B01-4861-98FB-271087E7FBEE")] -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/HadrModel/RestartSqlServerException.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | using System.Globalization; 5 | 6 | 7 | namespace Microsoft.SqlServer.Management.HadrModel 8 | { 9 | /// 10 | /// Restart SQL Server Exception 11 | /// Thrown from AddDomainUserInSQLAdminTask.RestartSqlServer method 12 | /// 13 | public class RestartSqlServerException : HadrTaskBaseException 14 | { 15 | /// 16 | /// Standard RestartSqlServerException with Instance Name 17 | /// 18 | /// target Sql Instance Name 19 | public RestartSqlServerException(string InstanceName) 20 | : base(string.Format(CultureInfo.InvariantCulture, Resource.RestartSqlServerException, InstanceName)) 21 | { 22 | } 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/HadrModel/RestoreDatabaseTaskException.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | using System; 5 | using System.Globalization; 6 | 7 | namespace Microsoft.SqlServer.Management.HadrModel 8 | { 9 | /// 10 | /// This exception is thrown when RestoreDatabaseTask.perform fail 11 | /// 12 | public class RestoreDatabaseTaskException : HadrTaskBaseException 13 | { 14 | /// 15 | /// Exception with DatabaseName and inner exception 16 | /// 17 | public RestoreDatabaseTaskException(string DatabaseName, Exception inner) 18 | : base(string.Format(CultureInfo.InvariantCulture, Resource.RestoreDatabaseTaskExcption, DatabaseName), inner) 19 | { 20 | } 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/HadrModel/RestoreLogTaskException.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | using System; 5 | using System.Globalization; 6 | 7 | namespace Microsoft.SqlServer.Management.HadrModel 8 | { 9 | /// 10 | /// This exception is thrown when RestoreLogTask.perform fail 11 | /// 12 | public class RestoreLogTaskException : HadrTaskBaseException 13 | { 14 | /// 15 | /// Exception with DatabaseName and inner exception 16 | /// 17 | public RestoreLogTaskException(string DatabaseName,Exception inner) 18 | : base(string.Format(CultureInfo.InvariantCulture, Resource.RestoreLogTaskException, DatabaseName), inner) 19 | { 20 | } 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/HadrModel/SqlServerConnectionException.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | using System.Globalization; 5 | 6 | namespace Microsoft.SqlServer.Management.HadrModel 7 | { 8 | /// 9 | /// Add Domain User In AdminGroup Task Exception 10 | /// 11 | public class SqlServerConnectionException : HadrTaskBaseException 12 | { 13 | /// 14 | /// Standard SqlServerConnectionException with domain user name 15 | /// 16 | /// 17 | public SqlServerConnectionException(string VMIPAddress) 18 | : base(string.Format(CultureInfo.InvariantCulture, Resource.AddDomainUserInAdminGroupTaskException, VMIPAddress)) 19 | { 20 | } 21 | 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/HadrModel/TaskEventStatus.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | 5 | namespace Microsoft.SqlServer.Management.HadrModel 6 | { 7 | public enum TaskEventStatus 8 | { 9 | /// 10 | /// Not Start state 11 | /// 12 | NotStart, 13 | 14 | /// 15 | /// Started 16 | /// 17 | Started, 18 | 19 | /// 20 | /// Cancelled 21 | /// 22 | Cancelled, 23 | 24 | /// 25 | /// Running 26 | /// 27 | Running, 28 | 29 | /// 30 | /// Failed 31 | /// 32 | Failed, 33 | 34 | /// 35 | /// Complete 36 | /// 37 | Completed 38 | } 39 | } 40 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/PolicyEnum/FxCopExclusions.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | using System.Diagnostics.CodeAnalysis; 5 | 6 | [module: SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode", Scope = "member", Target = "AssemblyVersionInfo.get_VersionHelpNamespace():System.String")] 7 | [module: SuppressMessage("Microsoft.Performance", "CA1812:AvoidUninstantiatedInternalClasses", Scope = "type", Target = "Microsoft.SqlServer.Management.Dmf.PolicyObject")] 8 | [module: SuppressMessage("Microsoft.Performance", "CA1812:AvoidUninstantiatedInternalClasses", Scope = "type", Target = "Microsoft.SqlServer.Management.Dmf.Util")] 9 | 10 | 11 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/PolicyEnum/PolicyEnum.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | 5 | namespace Microsoft.SqlServer.Management.Dmf 6 | { 7 | 8 | } 9 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/PolicyEnum/PolicyObject.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | namespace Microsoft.SqlServer.Management.Dmf 5 | { 6 | using System; 7 | using System.Reflection; 8 | using Microsoft.SqlServer.Management.Common; 9 | using Microsoft.SqlServer.Management.Sdk.Sfc; 10 | 11 | internal sealed class PolicyObject : SqlObject, Microsoft.SqlServer.Management.Sdk.Sfc.ISupportVersions 12 | { 13 | public override Assembly ResourceAssembly 14 | { 15 | get 16 | { 17 | return Assembly.GetExecutingAssembly(); 18 | } 19 | } 20 | 21 | public ServerVersion GetServerVersion(Object conn) 22 | { 23 | return ExecuteSql.GetServerVersion(conn); 24 | } 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/PolicyEnum/xml/ObjectSet.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | os.object_set_id 9 | os.object_set_name 10 | ISNULL(os.facet_name,N'') 11 | 12 | CAST(0 AS bit) 13 | 14 | 15 | os.is_system 16 | 17 | 18 | 19 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/PolicyEnum/xml/PolicyCategory.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | pc.policy_category_id 9 | pc.name 10 | pc.mandate_database_subscriptions 11 | 12 | 13 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/PolicyEnum/xml/PolicyCategorySubscription.xml: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | pgs.policy_category_id = categories.policy_category_id 6 | 7 | 8 | 9 | pgs.policy_category_subscription_id 10 | pgs.target_type 11 | pgs.target_object 12 | categories.name 13 | 14 | 15 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/PolicyEnum/xml/TargetFilter.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | tf.target_filter_id 12 | 13 | tf.type 14 | tf.filter 15 | tf.type_skeleton 16 | 17 | 18 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/PolicyEnum/xml/inc_urn.xml: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/PolicyEnum/xml/inc_urnByID.xml: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/RegisteredServers/xml/RegisteredServersStore.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | declare @tmp_shared_server_store_stub TABLE 7 | (ID int) 8 | insert into @tmp_shared_server_store_stub (ID) values (0) 9 | 10 | 11 | 12 | N'RegisteredServersStore' 13 | store.ID 14 | 15 | 16 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/RegisteredServers/xml/inc_urn.xml: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Sdk/Sfc/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | using System.Security; 5 | 6 | // make code access security compatible with Netfx 2.0 7 | [assembly: SecurityRules(SecurityRuleSet.Level1)] -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Sdk/Sfc/Differencing/Differencing.vsmdi: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Sdk/Sfc/Differencing/LocalTestRun.testrunconfig: -------------------------------------------------------------------------------- 1 |  2 | 3 | This is a default test run configuration for a local test run. 4 | 5 | 6 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Sdk/Sfc/Enumerator/Filter.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | namespace Microsoft.SqlServer.Management.Sdk.Sfc 5 | { 6 | internal class Filter : AstNode { 7 | private AstNode _input; 8 | private AstNode _condition; 9 | 10 | internal Filter( AstNode input, AstNode condition) { 11 | _input = input; 12 | _condition = condition; 13 | } 14 | 15 | internal override QueryType TypeOfAst { 16 | get {return QueryType.Filter;} 17 | } 18 | 19 | internal override RType ReturnType { 20 | get {return RType.NodeSet;} 21 | } 22 | 23 | internal AstNode Input { 24 | get { return _input;} 25 | } 26 | 27 | internal AstNode Condition { 28 | get {return _condition;} 29 | } 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Sdk/Sfc/Enumerator/Group.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | namespace Microsoft.SqlServer.Management.Sdk.Sfc 5 | { 6 | internal class Group : AstNode { 7 | private AstNode _groupNode; 8 | 9 | internal Group(AstNode groupNode) { 10 | _groupNode = groupNode; 11 | } 12 | internal override QueryType TypeOfAst { 13 | get {return QueryType.Group;} 14 | } 15 | internal override RType ReturnType { 16 | get {return RType.NodeSet;} 17 | } 18 | 19 | internal AstNode GroupNode { 20 | get {return _groupNode;} 21 | } 22 | 23 | internal override double DefaultPriority { 24 | get { 25 | //return _groupNode.DefaultPriority; 26 | return 0; 27 | } 28 | } 29 | } 30 | } 31 | 32 | 33 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Sdk/Sfc/Enumerator/Root.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | namespace Microsoft.SqlServer.Management.Sdk.Sfc 5 | { 6 | internal class Root : AstNode { 7 | internal Root() { 8 | } 9 | 10 | internal override QueryType TypeOfAst { 11 | get {return QueryType.Root;} 12 | } 13 | 14 | internal override RType ReturnType { 15 | get {return RType.NodeSet;} 16 | } 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Sdk/Sfc/Enumerator/XPathNodeType.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | namespace Microsoft.SqlServer.Management.Sdk.Sfc 5 | { 6 | internal enum XPathNodeType { 7 | Root, 8 | Element, 9 | Attribute, 10 | #if SupportNamespaces 11 | Namespace, 12 | #endif 13 | Text, 14 | SignificantWhitespace, 15 | Whitespace, 16 | ProcessingInstruction, 17 | Comment, 18 | All, 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Sdk/Sfc/ISfcExecutionEngine.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | namespace Microsoft.SqlServer.Management.Sdk.Sfc 5 | { 6 | /// 7 | /// ISfcExecutionEngine is an abstraction over a domain-provided component that is able to execute an ISfcScript 8 | /// 9 | public interface ISfcExecutionEngine 10 | { 11 | /// 12 | /// Execute a script 13 | /// 14 | /// Script to be executed 15 | object Execute(ISfcScript script); 16 | } 17 | } -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Sdk/Sfc/ISfcNotifyPropertyChanged.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | using System; 5 | using System.ComponentModel; 6 | 7 | namespace Microsoft.SqlServer.Management.Sdk.Sfc 8 | { 9 | /// 10 | /// Notifies clients that a property metadata has changed. 11 | /// 12 | public interface ISfcNotifyPropertyMetadataChanged 13 | { 14 | event EventHandler PropertyMetadataChanged; 15 | } 16 | 17 | public class SfcPropertyMetadataChangedEventArgs : PropertyChangedEventArgs 18 | { 19 | public SfcPropertyMetadataChangedEventArgs(string propertyName) 20 | : base(propertyName) 21 | { 22 | } 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Sdk/Sfc/ISfcPropertyProvider.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | using System.ComponentModel; 5 | 6 | namespace Microsoft.SqlServer.Management.Sdk.Sfc 7 | { 8 | /// 9 | /// This interface needs to be provided by top level classes (or by a base class of a top level class). 10 | /// It provides an interface into the object's properties. 11 | /// 12 | public interface ISfcPropertyProvider : ISfcNotifyPropertyMetadataChanged, INotifyPropertyChanged 13 | { 14 | /// 15 | /// Gets the interface reference to the set of properties of this object 16 | /// 17 | /// 18 | ISfcPropertySet GetPropertySet(); 19 | } 20 | 21 | } 22 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Sdk/Sfc/ISfcScriptCollector.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | namespace Microsoft.SqlServer.Management.Sdk.Sfc 5 | { 6 | /// 7 | /// Provide an access to the Script Collector instance 8 | /// 9 | public interface ISfcScriptCollector 10 | { 11 | /// 12 | /// Opens writer of the supplied type 13 | /// 14 | /// type of the writer 15 | /// 16 | T OpenWriter(); 17 | 18 | /// 19 | /// Opens or Reopens writer of the supplied type 20 | /// 21 | /// type of the writer 22 | /// indicates that previous writer of the same type should be reused 23 | /// 24 | T OpenWriter(bool append); 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Sdk/Sfc/ISfcSupportsDesignMode.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | namespace Microsoft.SqlServer.Management.Sdk.Sfc 5 | { 6 | /// 7 | /// The interface's only purpose is to 'mark' types that we want to work in Design Mode. 8 | /// A type (class) needs to inherit from this interface if it wants to work in Design Mode. 9 | /// That mechanism also allows a client of the model to programmatically discover which classes 10 | /// support Design Mode, which can be useful in certain scenarios. 11 | /// 12 | public interface ISfcSupportsDesignMode 13 | { 14 | bool IsDesignMode { get; } 15 | } 16 | } 17 | 18 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Sdk/Sfc/ISfcscript.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | namespace Microsoft.SqlServer.Management.Sdk.Sfc 5 | { 6 | /// 7 | /// ISfcScript interface is an abstraction over a script concept. Most domains would implement 8 | /// this interface via text 9 | /// 10 | public interface ISfcScript 11 | { 12 | /// 13 | /// Add a "batch" to the script to be executed individually 14 | /// 15 | /// Partial Script 16 | void Add(ISfcScript script); 17 | } 18 | } -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Sdk/Sfc/TypeMetadata.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | 5 | namespace Microsoft.SqlServer.Management.Sdk.Sfc 6 | { 7 | /// 8 | /// Provide type metadata for the object (information that doesn't change with every instance) 9 | /// 10 | public abstract class SfcTypeMetadata 11 | { 12 | public abstract bool IsCrudActionHandledByParent( SfcDependencyAction dependencyAction ); 13 | } 14 | } -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Smo.Broker/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | using System.Security; 5 | 6 | // make code access security compatible with Netfx 2.0 7 | [assembly: SecurityRules(SecurityRuleSet.Level1)] -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Smo.Broker/ServiceBrokerEnum.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | using System.Diagnostics.CodeAnalysis; 5 | 6 | namespace Microsoft.SqlServer.Management.Smo.Broker 7 | { 8 | 9 | [SuppressMessage("Microsoft.Design", "CA1008:EnumsShouldHaveZeroValue")] 10 | public enum DialogEndPointState 11 | { 12 | Open = 1, 13 | OpenWait = 2, 14 | Disabled = 6, 15 | ClosingWait = 7, 16 | ErrorWait = 8, 17 | ClosedWait = 9 18 | } 19 | 20 | public enum DialogType 21 | { 22 | Regular2Way = 0, 23 | MonologPublish, 24 | MonologReceive 25 | } 26 | 27 | public enum MessageTypeValidation 28 | { 29 | None = 0, 30 | XmlSchemaCollection, 31 | Empty, 32 | Xml 33 | } 34 | 35 | public enum MessageSource 36 | { 37 | Initiator = 0, 38 | Target, 39 | InitiatorAndTarget 40 | } 41 | } 42 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Smo.Broker/xml/ServiceContractMapping.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | sc.service_contract_id = scu.service_contract_id 9 | 10 | 11 | 12 | 13 | 14 | sc.name 15 | 16 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Smo.Broker/xml/inc_ext_prop.xml: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Smo.Broker/xml/inc_urn.xml: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Smo.Broker/xml/inc_urn_schema.xml: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Smo.Notebook/MarkdownCellModel.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | namespace Microsoft.SqlServer.Management.Smo.Notebook 5 | { 6 | /// 7 | /// A cell of type markdown 8 | /// 9 | internal class MarkdownCellModel : CellModel 10 | { 11 | /// 12 | /// Constructs an empty MarkdownCellModel 13 | /// 14 | public MarkdownCellModel() : base("markdown") 15 | { 16 | 17 | } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Smo.Notebook/Microsoft.SqlServer.Smo.Notebook.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | $(MSBuildAllProjects);$(MSBuildThisFileFullPath) 4 | $(TargetFrameworks) 5 | Microsoft.SqlServer.Management.Smo.Notebook 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Smo.RegSvrEnum/GroupRegistrationInfo.cs: -------------------------------------------------------------------------------- 1 | 2 | namespace Microsoft.SqlServer.Management.Smo.RegSvrEnum 3 | { 4 | /// 5 | /// 6 | /// 7 | public class GroupRegistrationInfo : ParentRegistrationInfo 8 | { 9 | public GroupRegistrationInfo() 10 | : base() 11 | { 12 | } 13 | 14 | 15 | 16 | internal override void SaveNodeToXml(System.Xml.XmlWriter writer, bool saveName) 17 | { 18 | writer.WriteStartElement("Group", null); 19 | writer.WriteAttributeString("name", null, this.FriendlyName); 20 | writer.WriteAttributeString("description", null, this.Description); 21 | 22 | // write out all of the children 23 | foreach(RegistrationInfo reg in this.Children) 24 | { 25 | reg.SaveNodeToXml(writer, saveName); 26 | } 27 | writer.WriteEndElement(); 28 | } 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Smo.RegSvrEnum/Microsoft.SqlServer.RegSvrEnum.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | $(MSBuildAllProjects);$(MSBuildThisFileFullPath) 4 | $(NetFxVersion) 5 | Microsoft.SqlServer.Management.Smo.RegSvrEnum 6 | true 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Smo.RegSvrEnum/Tracing.cs: -------------------------------------------------------------------------------- 1 | #if STRACE 2 | using Microsoft.SqlServer.Management.Diagnostics; 3 | #endif 4 | 5 | namespace Microsoft.SqlServer.Management.Smo.RegSvrEnum 6 | { 7 | /// 8 | /// Holds constants for use with the Managed Trace Provider 9 | /// 10 | internal sealed class Tracing 11 | { 12 | public const string ConnDialog = "ConnectionDialog"; 13 | public const string RegProvider = "RegistrationProvider"; 14 | #if STRACE 15 | public const uint NormalTrace = SQLToolsCommonTraceLvl.L2; 16 | public const uint Error = SQLToolsCommonTraceLvl.Error; 17 | public const uint Warning = SQLToolsCommonTraceLvl.Warning; 18 | #endif 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Smo.Wmi/ServerInstanceBase.cs: -------------------------------------------------------------------------------- 1 | namespace Microsoft.SqlServer.Management.Smo.Wmi 2 | { 3 | public partial class ServerInstance : WmiSmoObject 4 | { 5 | internal ServerInstance(WmiCollectionBase parentColl, string name) : 6 | base(parentColl, name) 7 | { 8 | } 9 | 10 | // returns the name of the type in the urn expression 11 | internal static string UrnSuffix 12 | { 13 | get 14 | { 15 | return "ServerInstance"; 16 | } 17 | } 18 | 19 | ServerProtocolCollection m_ServerProtocols = null; 20 | public ServerProtocolCollection ServerProtocols 21 | { 22 | get 23 | { 24 | if(m_ServerProtocols == null) 25 | { 26 | m_ServerProtocols = new ServerProtocolCollection(this); 27 | } 28 | return m_ServerProtocols; 29 | } 30 | } 31 | 32 | } 33 | } 34 | 35 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Smo.Wmi/coll_macros.h: -------------------------------------------------------------------------------- 1 | #ifndef COLLECTION_SUFFIX 2 | #define COLLECTION_SUFFIX Collection 3 | #endif 4 | 5 | #ifdef SEALED 6 | #define SEALED_IMP sealed 7 | #else 8 | #define SEALED_IMP 9 | #endif 10 | 11 | #define IDENTITY(x) x 12 | #define TOKEN_PASTE(x,y) IDENTITY(x)##IDENTITY(y) 13 | #define TOKEN_PASTE3(x,y,z) IDENTITY(x)##IDENTITY(y)##IDENTITY(z) 14 | 15 | #define STRINGIZE(x) #x 16 | #define STRINGER(x) STRINGIZE(x) 17 | 18 | 19 | #ifndef PARTIAL_KEYWORD 20 | #define PARTIAL_KEYWORD 21 | #endif 22 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Smo.WmiEnum/CNetLibInfo.cs: -------------------------------------------------------------------------------- 1 | namespace Microsoft.SqlServer.Management.Smo.Wmi 2 | { 3 | using System; 4 | using System.Text; 5 | using System.Management; 6 | 7 | internal class CNetLibInfo : WmiBase 8 | { 9 | public CNetLibInfo() : base("ClientNetLibInfo") 10 | { 11 | WmiProperty wp = null; 12 | 13 | wp = new WmiProperty("FileName", "System.String"); 14 | AddProperty(wp); 15 | 16 | wp = new WmiProperty("Version", "System.String"); 17 | AddProperty(wp); 18 | 19 | wp = new WmiProperty("Date", "System.UInt32"); 20 | AddProperty(wp); 21 | 22 | wp = new WmiProperty("Size", "System.UInt32"); 23 | AddProperty(wp); 24 | 25 | wp = new WmiProperty("ProtocolName", "System.String"); 26 | AddProperty(wp); 27 | } 28 | 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Smo.WmiEnum/ClientProtocolProperties.cs: -------------------------------------------------------------------------------- 1 | namespace Microsoft.SqlServer.Management.Smo.Wmi 2 | { 3 | using System; 4 | using System.Text; 5 | using System.Management; 6 | 7 | internal class ClientProtocolProperties : ProtocolPropertiesBase 8 | { 9 | public ClientProtocolProperties() : base("ClientNetworkProtocolProperty") 10 | { 11 | WmiProperty wp = null; 12 | 13 | wp = new WmiProperty("Idx", "System.UInt32"); 14 | wp.PhysicalName = "PropertyIdx"; 15 | AddProperty(wp); 16 | } 17 | 18 | protected override string[] GetParentFields() 19 | { 20 | return new String [] { "Name"}; 21 | } 22 | 23 | protected override string GetWhereClauseTemplate() 24 | { 25 | return "(ProtocolName=\"{0}\")"; 26 | } 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Smo.WmiEnum/FxCopExclusions.cs: -------------------------------------------------------------------------------- 1 | using System.Diagnostics.CodeAnalysis; 2 | 3 | [module: SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode", Scope = "member", Target = "Microsoft.SqlServer.Management.Smo.Wmi.Service.StringToEnum(System.String[],System.Management.ManagementObject,System.String):System.Int32")] 4 | [module: SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode", Scope = "member", Target = "Microsoft.SqlServer.Management.Smo.Wmi.Service.GetIndex(System.String[],System.String):System.Int32")] 5 | 6 | [module: SuppressMessage("Microsoft.Globalization", "CA1305:SpecifyIFormatProvider", Scope = "member", Target = "Microsoft.SqlServer.Management.Smo.Wmi.Res.GetString(System.String,System.Object[]):System.String", MessageId = "System.String.Format(System.String,System.Object[])")] -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Smo.WmiEnum/SAlias.cs: -------------------------------------------------------------------------------- 1 | namespace Microsoft.SqlServer.Management.Smo.Wmi 2 | { 3 | using System; 4 | using System.Text; 5 | using System.Management; 6 | 7 | internal class SAlias : WmiBase 8 | { 9 | public SAlias() : base("SqlServerAlias") 10 | { 11 | WmiProperty wp = null; 12 | 13 | wp = new WmiProperty("Name", "System.String"); 14 | wp.PhysicalName = "AliasName"; 15 | AddProperty(wp); 16 | 17 | wp = new WmiProperty("ServerName", "System.String"); 18 | AddProperty(wp); 19 | 20 | wp = new WmiProperty("ProtocolName", "System.String"); 21 | AddProperty(wp); 22 | 23 | wp = new WmiProperty("ConnectionString", "System.String"); 24 | AddProperty(wp); 25 | } 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Smo.WmiEnum/ServerInstance.cs: -------------------------------------------------------------------------------- 1 | namespace Microsoft.SqlServer.Management.Smo.Wmi 2 | { 3 | using System; 4 | using System.Text; 5 | using System.Management; 6 | using Microsoft.SqlServer.Management.Sdk.Sfc; 7 | 8 | internal class ServerInstance : WmiBase 9 | { 10 | public ServerInstance() 11 | : base("ServerSettings") 12 | { 13 | WmiProperty wp = new WmiProperty("Name", "System.String"); 14 | wp.PhysicalName = "InstanceName"; 15 | AddProperty(wp); 16 | } 17 | 18 | public override EnumResult GetData(EnumResult erParent) 19 | { 20 | WmiRequest w = this.Request as WmiRequest; 21 | if( null != w && true == w.RequestingTheWhereClause ) 22 | { 23 | WmiEnumResult er = new WmiEnumResult(((WmiEnumResult)erParent).Scope); 24 | er.WhereClause = GetXpathFilter(); 25 | return er; 26 | } 27 | return base.GetData(erParent); 28 | } 29 | } 30 | } 31 | 32 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Smo.WmiEnum/ServerProtocolIPAddressProperty.cs: -------------------------------------------------------------------------------- 1 | namespace Microsoft.SqlServer.Management.Smo.Wmi 2 | { 3 | using System; 4 | using System.Text; 5 | using System.Management; 6 | using System.Data; 7 | 8 | internal class ServerProtocolIPAddressProperty : ProtocolPropertiesBase 9 | { 10 | public ServerProtocolIPAddressProperty() : base("ServerNetworkProtocolProperty") 11 | { 12 | } 13 | 14 | protected override string[] GetParentFields() 15 | { 16 | return new String [] { "Name", "ProtocolName", "InstanceName" }; 17 | } 18 | 19 | protected override string GetWhereClauseTemplate() 20 | { 21 | return "(IPAddressName=\"{0}\" and ProtocolName=\"{1}\" and InstanceName=\"{2}\")"; 22 | } 23 | 24 | } 25 | } 26 | 27 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Smo.WmiEnum/ServerProtocolProperties.cs: -------------------------------------------------------------------------------- 1 | namespace Microsoft.SqlServer.Management.Smo.Wmi 2 | { 3 | using System; 4 | using System.Text; 5 | using System.Management; 6 | 7 | internal class ServerProtocolProperties : ProtocolPropertiesBase 8 | { 9 | public ServerProtocolProperties() : base("ServerNetworkProtocolProperty") 10 | { 11 | } 12 | 13 | protected override string[] GetParentFields() 14 | { 15 | return new String [] { "Name", "InstanceName" }; 16 | } 17 | 18 | protected override string GetWhereClauseTemplate() 19 | { 20 | return "(IPAddressName=\"\" and ProtocolName=\"{0}\" and InstanceName=\"{1}\")"; 21 | } 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Smo.WmiEnum/wmienumresult.cs: -------------------------------------------------------------------------------- 1 | namespace Microsoft.SqlServer.Management.Smo.Wmi 2 | { 3 | using System; 4 | using Microsoft.SqlServer.Management.Sdk.Sfc; 5 | 6 | internal class WmiEnumResult : EnumResult 7 | { 8 | string m_scope; 9 | string m_whereClause; 10 | 11 | public string Scope 12 | { 13 | get { return m_scope; } 14 | set { m_scope = value; } 15 | } 16 | 17 | public string WhereClause 18 | { 19 | get { return m_whereClause; } 20 | set { m_whereClause = value; } 21 | } 22 | 23 | 24 | public WmiEnumResult(string scope) : base(null, ResultType.Reserved1) 25 | { 26 | this.Scope = scope; 27 | } 28 | } 29 | } 30 | 31 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Smo.WmiEnum/wmirequest.cs: -------------------------------------------------------------------------------- 1 | namespace Microsoft.SqlServer.Management.Smo.Wmi 2 | { 3 | using System; 4 | using Microsoft.SqlServer.Management.Sdk.Sfc; 5 | 6 | internal class WmiRequest : Request 7 | { 8 | bool bRequestingTheWhereClause = false; 9 | 10 | internal bool RequestingTheWhereClause 11 | { 12 | 13 | get { return bRequestingTheWhereClause; } 14 | set { bRequestingTheWhereClause = value; } 15 | } 16 | } 17 | } 18 | 19 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Smo/AlertCategoryBase.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | namespace Microsoft.SqlServer.Management.Smo.Agent 5 | { 6 | public partial class AlertCategory : CategoryBase 7 | { 8 | internal AlertCategory(AbstractCollectionBase parentColl, ObjectKeyBase key, SqlSmoState state) : 9 | base(parentColl, key, state) 10 | { 11 | } 12 | 13 | // returns the name of the type in the urn expression 14 | public static string UrnSuffix 15 | { 16 | get 17 | { 18 | return "AlertCategory"; 19 | } 20 | } 21 | 22 | 23 | internal override string GetCategoryClassName() 24 | { 25 | return "ALERT"; 26 | } 27 | 28 | internal override int GetCategoryClass() 29 | { 30 | return 2; 31 | } 32 | 33 | } 34 | } 35 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Smo/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | using System.Security; 5 | 6 | // make code access security compatible with Netfx 2.0 7 | [assembly: SecurityRules(SecurityRuleSet.Level1)] 8 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Smo/DistributionColumnBase.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using Microsoft.SqlServer.Management.Sdk.Sfc; 3 | using Microsoft.SqlServer.Management.Common; 4 | using System.Collections.Generic; 5 | 6 | namespace Microsoft.SqlServer.Management.Smo 7 | { 8 | public partial class DistributionColumn : NamedSmoObject 9 | { 10 | internal DistributionColumn(AbstractCollectionBase parentColl, ObjectKeyBase key, SqlSmoState state) : 11 | base(parentColl, key, state) 12 | { 13 | } 14 | 15 | // returns the name of the type in the urn expression 16 | internal static string UrnSuffix 17 | { 18 | get 19 | { 20 | return "DistributionColumn"; 21 | } 22 | } 23 | 24 | } 25 | } 26 | 27 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Smo/ModuleSuppressions.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | #if CODE_ANALYSIS 5 | using System.Diagnostics.CodeAnalysis; 6 | 7 | // Resources 8 | [module: SuppressMessage("Microsoft.Naming", "CA1703:ResourceStringsShouldBeSpelledCorrectly", Scope="resource", Target="Microsoft.SqlServer.Management.Smo.ExceptionTemplates.resources", MessageId="vacuumer", Justification="'Vacuumer' is the name of an NS component")] 9 | 10 | #endif 11 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Smo/OperatorCategoryBase.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | namespace Microsoft.SqlServer.Management.Smo.Agent 5 | { 6 | public partial class OperatorCategory : CategoryBase 7 | { 8 | internal OperatorCategory(AbstractCollectionBase parentColl, ObjectKeyBase key, SqlSmoState state) : 9 | base(parentColl, key, state) 10 | { 11 | } 12 | 13 | // returns the name of the type in the urn expression 14 | public static string UrnSuffix 15 | { 16 | get 17 | { 18 | return "OperatorCategory"; 19 | } 20 | } 21 | 22 | 23 | internal override string GetCategoryClassName() 24 | { 25 | return "OPERATOR"; 26 | } 27 | 28 | internal override int GetCategoryClass() 29 | { 30 | return 3; 31 | } 32 | 33 | } 34 | } 35 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Smo/ScriptStringBuilder/IScriptStringBuilderParameter.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | namespace Microsoft.SqlServer.Management.Smo 5 | { 6 | /// 7 | /// Interface used for parameters of ScriptStringBuilder 8 | /// 9 | internal interface IScriptStringBuilderParameter 10 | { 11 | /// 12 | /// Gets the parameter's key 13 | /// 14 | /// Parameter's key as a string 15 | string GetKey(); 16 | 17 | /// 18 | /// Gets the TSQL script representation of this parameter 19 | /// 20 | /// This parameter as TSQL script 21 | string ToScript(); 22 | } 23 | } -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Smo/ScriptStringBuilder/ParameterValueFormat.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | namespace Microsoft.SqlServer.Management.Smo 5 | { 6 | /// 7 | /// How a parameter value in a SMO script should be formatted 8 | /// 9 | internal enum ParameterValueFormat 10 | { 11 | /// 12 | /// Not quoted, e.g. value = 2 13 | /// 14 | NotString, 15 | 16 | /// 17 | /// Quoted as a CHAR, e.g. value = '2' 18 | /// 19 | CharString, 20 | 21 | /// 22 | /// 23 | /// 24 | NVarCharString 25 | } 26 | } -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Smo/SearchPropertyListConstants.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | using System; 5 | 6 | namespace Microsoft.SqlServer.Management.Smo 7 | { 8 | /// 9 | /// static internal class to isolate the DDL changes 10 | /// related to SearchPropertyList 11 | /// 12 | static class SearchPropertyListConstants 13 | { 14 | public const String SearchPropertyList = "SEARCH PROPERTY LIST"; 15 | public const String SearchProperty = "SEARCH PROPERTY"; 16 | 17 | public const int MaxSearchPropertyListNameLength = 256; 18 | public const int MaxSearchPropertyNameLength = 256; 19 | public const int MaxSearchPropertyDescriptionLength = 512; 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Smo/ServerAuditSpecificationbase.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | namespace Microsoft.SqlServer.Management.Smo 5 | { 6 | [Facets.EvaluationMode(Dmf.AutomatedPolicyEvaluationMode.CheckOnSchedule)] 7 | [Microsoft.SqlServer.Management.Sdk.Sfc.PhysicalFacet] 8 | public partial class ServerAuditSpecification : AuditSpecification 9 | { 10 | internal ServerAuditSpecification(AbstractCollectionBase parentColl, ObjectKeyBase key, SqlSmoState state) : 11 | base(parentColl, key, state) { } 12 | 13 | public static string UrnSuffix 14 | { 15 | get 16 | { 17 | return "ServerAuditSpecification"; 18 | } 19 | } 20 | 21 | internal static string ParentType 22 | { 23 | get 24 | { 25 | return "SERVER"; 26 | } 27 | } 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Smo/TargetServerBase.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | namespace Microsoft.SqlServer.Management.Smo.Agent 5 | { 6 | public partial class TargetServer : AgentObjectBase 7 | { 8 | internal TargetServer(AbstractCollectionBase parentColl, ObjectKeyBase key, SqlSmoState state) : 9 | base(parentColl, key, state) 10 | { 11 | } 12 | 13 | // returns the name of the type in the urn expression 14 | public static string UrnSuffix 15 | { 16 | get 17 | { 18 | return "TargetServer"; 19 | } 20 | } 21 | } 22 | 23 | 24 | } 25 | 26 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/Smo/coll_macros.h: -------------------------------------------------------------------------------- 1 | #ifndef COLLECTION_SUFFIX 2 | #define COLLECTION_SUFFIX Collection 3 | #endif 4 | 5 | #ifdef SEALED 6 | #define SEALED_IMP sealed 7 | #else 8 | #define SEALED_IMP 9 | #endif 10 | 11 | #define IDENTITY(x) x 12 | #define TOKEN_PASTE(x,y) IDENTITY(x)##IDENTITY(y) 13 | #define TOKEN_PASTE3(x,y,z) IDENTITY(x)##IDENTITY(y)##IDENTITY(z) 14 | 15 | #define STRINGIZE(x) #x 16 | #define STRINGER(x) STRINGIZE(x) 17 | 18 | 19 | #ifndef PARTIAL_KEYWORD 20 | #define PARTIAL_KEYWORD 21 | #endif 22 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SmoMetadataProvider/ISmoDatabaseObject.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | using Microsoft.SqlServer.Management.Smo; 5 | 6 | namespace Microsoft.SqlServer.Management.SmoMetadataProvider 7 | { 8 | /// 9 | /// Represents an object associated with SMO database metadata object. 10 | /// 11 | public interface ISmoDatabaseObject 12 | { 13 | /// 14 | /// Gets an object associated with this object. 15 | /// 16 | SqlSmoObject SmoObject { get; } 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SmoMetadataProvider/Microsoft.SqlServer.Management.SmoMetadataProvider.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | $(MSBuildAllProjects);$(MSBuildThisFileFullPath) 4 | $(TargetFrameworks) 5 | Microsoft.SqlServer.Management.SmoMetadataProvider 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SmoMetadataProvider/PrimaryKeyConstraint.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | using System; 5 | 6 | using Microsoft.SqlServer.Management.SqlParser.Metadata; 7 | 8 | namespace Microsoft.SqlServer.Management.SmoMetadataProvider 9 | { 10 | class PrimaryKeyConstraint : UniqueConstraintBase, IPrimaryKeyConstraint 11 | { 12 | public PrimaryKeyConstraint(IDatabaseTable parent, IRelationalIndex index) 13 | : base(parent, index) 14 | { 15 | } 16 | 17 | public override ConstraintType Type 18 | { 19 | get { return ConstraintType.PrimaryKey; } 20 | } 21 | 22 | public override T Accept(IMetadataObjectVisitor visitor) 23 | { 24 | if (visitor == null) throw new ArgumentNullException("visitor"); 25 | 26 | return visitor.Visit(this); 27 | } 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SmoMetadataProvider/UniqueConstraint.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | using System; 5 | 6 | using Microsoft.SqlServer.Management.SqlParser.Metadata; 7 | 8 | namespace Microsoft.SqlServer.Management.SmoMetadataProvider 9 | { 10 | class UniqueConstraint : UniqueConstraintBase, IUniqueConstraint 11 | { 12 | public UniqueConstraint(IDatabaseTable parent, IRelationalIndex index) 13 | : base(parent, index) 14 | { 15 | } 16 | 17 | public override ConstraintType Type 18 | { 19 | get { return ConstraintType.Unique; } 20 | } 21 | 22 | public override T Accept(IMetadataObjectVisitor visitor) 23 | { 24 | if (visitor == null) throw new ArgumentNullException("visitor"); 25 | 26 | return visitor.Visit(this); 27 | } 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SmoMetadataProvider/XmlIndex.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | using System; 5 | using System.Diagnostics; 6 | 7 | using Microsoft.SqlServer.Management.SqlParser.Metadata; 8 | 9 | namespace Microsoft.SqlServer.Management.SmoMetadataProvider 10 | { 11 | class XmlIndex : Index, IXmlIndex 12 | { 13 | public XmlIndex(IDatabaseTable parent, Smo.Index smoIndex) 14 | : base(parent, smoIndex) 15 | { 16 | Debug.Assert(smoIndex.IsXmlIndex, "SmoMetadataProvider Assert", "Expected XML SMO index!"); 17 | } 18 | 19 | public override T Accept(IMetadataObjectVisitor visitor) 20 | { 21 | if (visitor == null) throw new ArgumentNullException("visitor"); 22 | 23 | return visitor.Visit(this); 24 | } 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | using System.Security; 5 | 6 | // make code access security compatible with Netfx 2.0 7 | [assembly: SecurityRules(SecurityRuleSet.Level1)] -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/PostProcessVersion.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | namespace Microsoft.SqlServer.Management.Smo 5 | { 6 | using System; 7 | 8 | internal class PostProcessVersion : PostProcess 9 | { 10 | public override object GetColumnData(string name, object data, DataProvider dp) 11 | { 12 | return ConvertToValidVersion (GetTriggeredInt32 (dp, 0), GetTriggeredInt32 (dp, 1), GetTriggeredInt32 (dp, 2), GetTriggeredInt32 (dp, 3)); 13 | } 14 | 15 | internal static Version ConvertToValidVersion (int major, int minor, int build, int revision) 16 | { 17 | return new Version ( 18 | -1 == major ? 0 : major, 19 | -1 == minor ? 0 : minor, 20 | -1 == build ? 0 : build, 21 | -1 == revision ? 0 : revision); 22 | } 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/CdromDrive.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | create table #cdromdrv ( Name sysname NOT NULL, Size int NOT NULL ) insert #cdromdrv EXECUTE master.dbo.xp_fixeddrives 3 6 | update #cdromdrv set Name = Name + ':' 7 | 8 | drop table #cdromdrv 9 | 10 | 11 | Name 12 | Size 13 | 14 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/ClusterMemberState.xml: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | cm.member_name 10 | cm.member_type 11 | ISNULL(cm.member_state, 2) 12 | ISNULL(cm.number_of_quorum_votes, -1) 13 | 14 | 15 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/ColumnEncryptionKey.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | cek.name 9 | cek.column_encryption_key_id 10 | cek.create_date 11 | cek.modify_date 12 | 13 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/ComputedText.xml: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | comt.colid 12 | comt.text 13 | cast(comt.id as nvarchar(20)) + N'_' + cast(comt.number as nvarchar(20)) + N'_' + cast(db_id() as nvarchar(20)) + N'_0' 15 | 16 | 17 | 18 | 19 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/ConfigurationValue.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | create table #tmp_sysmail_help_configure(paramname nvarchar(256), paramvalue nvarchar(256) null, description nvarchar(256) null) 7 | 8 | insert into #tmp_sysmail_help_configure(paramname, paramvalue, description) exec msdb.dbo.sysmail_help_configure_sp 9 | 10 | 11 | drop table #tmp_sysmail_help_configure 12 | 13 | 14 | 15 | 16 | tshc.paramname 17 | tshc.paramvalue 18 | tshc.description 19 | 20 | 21 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/DatabaseDdlTriggerEvent.xml: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | te.type 10 | te.type_desc 11 | 12 | cast(db_id() as varchar(20)) + '_' + cast(te.object_id as varchar(20)) 14 | 15 | 16 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/DbExtendedProperty.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | p.major_id=0 AND p.minor_id=0 AND p.class=0 9 | 10 | 11 | 12 | 13 | p.name 14 | p.value 15 | 16 | 17 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/DefaultColumn.xml: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/DefaultDatatype.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/ExternalLibraryFile.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | lfiles.external_library_id = library.external_library_id 9 | 10 | 11 | 12 | 13 | lfiles.platform_desc 14 | library.name 15 | lfiles.content 16 | 17 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/FullTextFile.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | ((s.type = 4) AND (s.drop_lsn IS NULL)) 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/FullTextLanguage.xml: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | ftl.name 8 | ftl.lcid 9 | 10 | 11 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/FulltextSemanticLanguage.xml: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | ftsl.lcid 9 | ftsl.name 10 | 11 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/KeyEncryption.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | ke.thumbprint 11 | (case ke.crypt_type when 'ESKS' then 0 when 'EPUC' then 1 when 'ESKP' then 2 when 'EPUA' then 3 when 'ESKM' then 4 end) 13 | 14 | ke.crypt_property 15 | 16 | 17 | 18 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/LogMarkHistory.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | l.database_name 8 | l.mark_name 9 | l.description 10 | l.user_name 11 | l.lsn 12 | l.mark_time 13 | 14 | 15 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/Mail.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/MailProfile.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | create table #tmp_sysmail_help_profile(profile_id int, name nvarchar(128), description nvarchar(256) null) 7 | 8 | insert into #tmp_sysmail_help_profile(profile_id, name, description) exec msdb.dbo.sysmail_help_profile_sp 9 | 10 | 11 | drop table #tmp_sysmail_help_profile 12 | 13 | 14 | 15 | 16 | tshp.name 17 | tshp.profile_id 18 | ISNULL(tshp.description,N'') 19 | 20 | 21 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/Mail_ErrorLog.xml: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | er.log_id 8 | er.event_type 9 | er.log_date 10 | er.description 11 | er.process_id 12 | er.mailitem_id 13 | er.account_id 14 | er.last_mod_date 15 | er.last_mod_user 16 | 17 | 18 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/MaintenancePlanDeprecated.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | s.plan_id 9 | s.plan_name 10 | s.date_created 11 | s.owner 12 | s.max_history_rows 13 | s.remote_history_server 14 | s.max_remote_history_rows 15 | 16 | s.log_shipping 17 | 18 | 19 | 20 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/NTLogin.xml: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | create table #tmpntlogin ( [Account name] sysname NULL, Type sysname NULL, [Privilege] sysname NULL, [Mapped login name] sysname NULL, [Permission path] sysname NULL) 6 | insert into #tmpntlogin exec master.dbo.xp_logininfo 7 | 8 | 9 | drop table #tmpntlogin 10 | 11 | 12 | 13 | [Account name] 14 | Type 15 | [Privilege] 16 | [Mapped login name] 17 | [Permission path] 18 | 19 | 20 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/NotificationServices/ApplicationDatabaseOptions.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | CREATE TABLE #tmp_AppDatabaseOptions ( 7 | SystemName nvarchar(255), 8 | DefaultFileGroup nvarchar(128), 9 | CollationName nvarchar(255) 10 | ) 11 | INSERT INTO #tmp_AppDatabaseOptions EXEC [SchemaPrefix].NSGetDatabaseOptions 12 | 13 | 14 | DROP TABLE #tmp_AppDatabaseOptions 15 | 16 | 17 | 18 | 19 | ado.SystemName 20 | ado.DefaultFileGroup 21 | ado.CollationName 22 | 23 | 24 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/NotificationServices/DeliveryChannel.xml: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | CREATE TABLE #tmp_delivery_channels( 7 | DeliveryChannelName nvarchar(255), 8 | ProtocolName nvarchar(255) 9 | ) 10 | INSERT #tmp_delivery_channels EXEC [SchemaPrefix].NSGetDeliveryChannels 11 | 12 | 13 | DROP TABLE #tmp_delivery_channels 14 | 15 | 16 | 17 | 18 | dcb.DeliveryChannelName 19 | dcb.ProtocolName 20 | 21 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/NotificationServices/InstanceDatabaseOptions.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | CREATE TABLE #tmp_InstDatabaseOptions ( 7 | SystemName nvarchar(255), 8 | DefaultFileGroup nvarchar(128), 9 | CollationName nvarchar(255) 10 | ) 11 | INSERT INTO #tmp_InstDatabaseOptions EXEC [SchemaPrefix].NSGetDatabaseOptions 12 | 13 | 14 | DROP TABLE #tmp_InstDatabaseOptions 15 | 16 | 17 | 18 | 19 | ido.SystemName 20 | ido.DefaultFileGroup 21 | ido.CollationName 22 | 23 | 24 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/NotificationServices/NotificationServices.xml: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 13 | 14 | serverproperty(N'Servername') 15 | 16 | 17 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/NotificationServices/ProtocolDefinition.xml: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | CREATE TABLE #tmp_protocol_definitions( 7 | ProtocolName nvarchar(255), 8 | ClassName nvarchar(255), 9 | AssemblyName nvarchar(260) 10 | ) 11 | INSERT #tmp_protocol_definitions EXEC [SchemaPrefix].NSGetProtocols 0 12 | 13 | 14 | DROP TABLE #tmp_protocol_definitions 15 | 16 | 17 | 18 | 19 | dpd.ProtocolName 20 | dpd.ClassName 21 | dpd.AssemblyName 22 | 23 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/OLEDBProvider.xml: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | create table #OLEDBProv ( Name sysname NOT NULL, ParseName sysname NOT 5 | NULL,Description sysname NOT NULL ) insert #OLEDBProv EXECUTE master.dbo.xp_enum_oledb_providers 6 | drop table #OLEDBProv 7 | 8 | 9 | 10 | 11 | op.Name 12 | op.ParseName 13 | op.Description 14 | 15 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/OrderColumn.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | clmns.object_id = oc.object_id and clmns.column_id = oc.column_id 9 | 10 | 11 | 12 | oc.order_column_id 13 | oc.is_descending 14 | clmns.name 15 | 16 | 17 | 18 | 19 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/PartitionFunctionRangeValue.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | sprv.boundary_id 10 | 11 | sprv.value 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/PartitionSchemeFileGroup.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | sf.data_space_id = sdd.data_space_id 12 | 13 | 14 | sf.name 15 | sdd.destination_id 16 | 17 | 18 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/PerfInfo.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | spi.cntr_type != 1073939459 6 | 7 | 8 | spi.cntr_type != 1073939712 9 | 10 | 11 | spi.cntr_type != 1073939712 12 | 13 | 14 | 15 | spi.object_name 16 | spi.counter_name 17 | ISNULL(spi.instance_name,N'') 18 | 19 | 20 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/RemoteDrive.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | create table #fixdrv ( Name sysname NOT NULL, Size int NOT NULL ) insert #fixdrv EXECUTE master.dbo.xp_fixeddrives 1 6 | update #fixdrv set Name = Name + ':' 7 | 8 | drop table #fixdrv 9 | 10 | 11 | Name 12 | Size 13 | 14 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/RemoteMaintenancePlan.xml: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | s.logged_remotely = 1 5 | 6 | 7 | s.plan_name 8 | 9 | 10 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/RemoteSubPlan.xml: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | s.logged_remotely = 1 5 | 6 | 7 | s.plan_name 8 | s.subplan_name 9 | s.source_server_name 10 | 11 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/RemovableDrive.xml: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | create table #fixdrv ( Name sysname NOT NULL, Size int NOT NULL ) insert #fixdrv EXECUTE master.dbo.xp_fixeddrives 2 6 | update #fixdrv set Name = Name + ':' 7 | 8 | drop table #fixdrv 9 | 10 | 11 | Name 12 | Size 13 | 14 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/RuleColumn.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/RuleDatatype.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/SPPerm.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | p.action in (193, 195, 196, 197, 224, 26) 9 | 10 | 11 | object_name(p.id) 12 | 13 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/SecurityPolicy.xml: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | sp.is_not_for_replication 11 | sp.is_enabled 12 | sp.is_schema_bound 13 | 14 | 15 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/ServerDdlTriggerEvent.xml: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | te.type 10 | te.type_desc 11 | cast(db_id() as varchar(20)) + '_' + cast(te.object_id as varchar(20)) 13 | 14 | 15 | 16 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/SqlAssemblyFile.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | afiles.name 13 | afiles.file_id 14 | afiles.content 15 | 16 | 17 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/TablePerm.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | (( p.action in (193, 197) and ((p.columns & 1) = 1) ) or ( p.action in (195, 196, 224, 26) )) 10 | and (convert(tinyint, substring( isnull(p.columns, 0x01), a.low, 1)) & a.high != 0) 11 | and a.type = N'P' 12 | and a.number = 0 13 | 14 | 15 | 16 | object_name(p.id) 17 | 18 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/TapeDevice.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | create table #tpdv ( Name nvarchar(512) NOT NULL) 5 | insert #tpdv (Name) EXECUTE master.dbo.xp_get_tape_devices 6 | 7 | drop table #tpdv 8 | 9 | 10 | Name 11 | 12 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/Text.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | c.colid 11 | case when c.number > 1 then c.number else 0 end 12 | c.text 13 | cast(c.id as nvarchar(20)) + N'_' + cast(db_id() as nvarchar(20)) + N'_' + cast(case when c.number > 1 then c.number else 0 end as nvarchar(20)) 15 | 16 | 17 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/agent_alert_categories.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | create table #tmp_sp_help_category 8 | (category_id int null, category_type tinyint null, name nvarchar(128) null) 9 | insert into #tmp_sp_help_category (category_id, category_type, name) exec msdb.dbo.sp_help_category 'ALERT' 10 | 11 | 12 | drop table #tmp_sp_help_category 13 | 14 | 15 | 16 | 17 | tshc.name 18 | tshc.category_id 19 | 20 | 21 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/agent_job_categories.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | create table #tmp_sp_help_category 8 | (category_id int null, category_type tinyint null, name nvarchar(128) null) 9 | insert into #tmp_sp_help_category (category_id, category_type, name) exec msdb.dbo.sp_help_category 'JOB' 10 | 11 | 12 | drop table #tmp_sp_help_category 13 | 14 | 15 | 16 | 17 | tshc.name 18 | tshc.category_id 19 | tshc.category_type 20 | 21 | 22 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/agent_jobalert.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/agent_operator_categories.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | create table #tmp_sp_help_category 8 | (category_id int null, category_type tinyint null, name nvarchar(128) null) 9 | insert into #tmp_sp_help_category (category_id, category_type, name) exec msdb.dbo.sp_help_category 'OPERATOR' 10 | 11 | 12 | drop table #tmp_sp_help_category 13 | 14 | 15 | 16 | 17 | tshc.name 18 | tshc.category_id 19 | 20 | 21 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/clusterSubnet.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | hcn.member_name 9 | hcn.network_subnet_ip 10 | hcn.network_subnet_ipv4_mask 11 | hcn.network_subnet_prefix_length 12 | hcn.is_public 13 | hcn.is_ipv4 14 | 15 | 16 | 17 | 18 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/edgeconstraint.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | cstr.is_system_named & 4 16 | cstr.delete_referential_action 17 | 18 | 19 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/endpoint/via_endpoint.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | ve.discriminator 13 | 14 | 15 | 16 | 17 | case when ve.endpoint_id < 65536 then 1 else 0 end 18 | 19 | 20 | 21 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/extendedproperty/inc_shilohExtendedProperty.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | p.name 12 | p.value 13 | 14 | 15 | 16 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/inc_column_reference.xml: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | tbl.id = {0}.id 7 | 8 | 9 | tbl.object_id = {0}.object_id 11 | 12 | 13 | 14 | {0}.name 15 | tbl.name 16 | 17 | user_name(tbl.uid) 18 | 19 | 20 | schema_name(tbl.schema_id) 21 | 22 | 23 | 24 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/inc_ddl_trigger_event.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 12 | null 13 | 14 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/inc_fulltext.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | {0}.definition 18 | 19 | 20 | 21 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/inc_partition_scheme_parent.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | CASE WHEN 'FG'=ds.type THEN ds.name ELSE N'' END 12 | CASE WHEN 'PS'=ds.type THEN ds.name ELSE N'' END 13 | CASE WHEN 'PS'=ds.type THEN 1 ELSE 0 END 14 | 15 | 16 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/inc_sql_module_JustText.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 12 | 13 | 14 | 16 | 21 | 22 | 23 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/inc_system_object.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | CASE WHEN (OBJECTPROPERTY({0}.id, N'IsMSShipped')=1) THEN 1 WHEN 1 = OBJECTPROPERTY({0}.id, N'IsSystemTable') THEN 1 ELSE 0 END 9 | 10 | 11 | 12 | 13 | {0}.is_ms_shipped 14 | 15 | 16 | 17 | 18 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/inc_urn.xml: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/inc_urn_collate_default.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/inc_urn_message.xml: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/inc_urn_single.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/inc_urn_soapmethod.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/perm/DBPerm.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | prmssn.id = 0 6 | 7 | 8 | prmssn.class = 0 9 | 10 | 11 | 12 | 13 | null 14 | 15 | 16 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/perm/ShilohYukonPerm.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | null 21 | 22 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/perm/SrvYukonObjectPerm.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | null 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/perm/SrvYukonPerm.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | prmssn.class = 100 6 | 7 | 8 | 9 | 10 | null 11 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/perm/TablePerm.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | (( prmssn.action in (193, 197) and ((prmssn.columns & 1) = 1) ) or ( prmssn.action in (195, 196, 224, 26) )) 8 | and (convert(tinyint, substring( isnull(prmssn.columns, 0x01), a.low, 1)) & a.high != 0) 9 | and a.type = N'P' 10 | and a.number = 0 11 | 12 | 13 | 14 | prmssn.minor_id = 0 15 | 16 | 17 | 18 | 20 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/perm/YukonObjectPerm.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | null 15 | 16 | 17 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/perm/YukonSchemaObjectPerm.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | null 15 | 16 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/perm/dbfixedroleperm.xml: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | usr.uid >= 16384 and 9 | usr.uid <= 16393 and 10 | spv.type = 'DBR' and 11 | ((usr.uid = 16384 and spv.number >= 16384 and spv.number < 16392) or (usr.uid <> 16384 and usr.uid = spv.number)) and 12 | spv.low > 0 13 | 14 | 15 | 16 | usr.name 17 | spv.name 18 | 19 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/primarychildren.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | declare @command nvarchar(300) 6 | select @command = 'dbcc checkprimaryfile (N''' + @fileName + ''' , 3)' 7 | create table #SmoPrimayChildren(status INT,fileid INT,name sysname,filename nvarchar(512)) 8 | insert #SmoPrimayChildren exec (@command) 9 | 10 | 11 | drop table #SmoPrimayChildren 12 | 13 | 14 | 15 | s.name 16 | s.fileid 17 | case when (s.status & 0x40) = 0 then 1 else 0 end 18 | RTRIM(s.filename) 19 | 20 | 21 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/primaryfile.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | declare @command nvarchar(300) 7 | select @command = 'dbcc checkprimaryfile (N'''+ @fileName + ''' , 2)' 8 | create table #smoPrimaryFileProp(property sql_variant NULL, value sql_variant NULL) 9 | insert #smoPrimaryFileProp exec (@command) 10 | 11 | drop table #smoPrimaryFileProp 12 | 13 | 14 | rtrim(@fileName) 15 | p.property 16 | p.value 17 | 18 | 19 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/restorefile.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | rtsf.file_number 12 | rtsf.destination_phys_drive 13 | rtsf.destination_phys_name 14 | 15 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/restorefilegroup.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | rtsfg.filegroup_name 12 | 13 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/servicemasterkey.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/temp_table.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | tbl.name like '#%' 5 | 6 | use tempdb 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/SqlEnum/xml/udfcolumn.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | clmns.number = <msparam>0</msparam> and <msparam>0</msparam> = OBJECTPROPERTY(clmns.id, N'IsScalarFunction') 6 | 7 | 8 | 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/XEvent/Server/ProviderConstants.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | namespace Microsoft.SqlServer.Management.XEvent 5 | { 6 | internal static class ProviderConstants 7 | { 8 | public const string Create = "CREATE "; 9 | public const string Drop = "DROP "; 10 | public const string Alter = "ALTER "; 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/XEvent/Server/ServerSessionProvider.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | using System; 5 | using System.Globalization; 6 | using Microsoft.SqlServer.Management.Sdk.Sfc; 7 | 8 | namespace Microsoft.SqlServer.Management.XEvent 9 | { 10 | /// 11 | /// Sql provider for Session at server scope. 12 | /// 13 | internal class ServerSessionProvider : SessionProviderBase 14 | { 15 | 16 | /// 17 | /// Constructs a ServerSessionProvider 18 | /// 19 | /// 20 | public ServerSessionProvider(Session session) : base(session, "SERVER") 21 | { 22 | } 23 | 24 | } 25 | } -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/XEvent/core/Constants.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | 5 | namespace Microsoft.SqlServer.Management.XEvent 6 | { 7 | internal class Constants 8 | { 9 | public static string ModuleName = "XEventObjectModel"; 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/XEvent/core/Predicate.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | 5 | namespace Microsoft.SqlServer.Management.XEvent 6 | { 7 | /// 8 | /// Predicate is the base class of all predicate related classes. 9 | /// 10 | public abstract class Predicate 11 | { 12 | 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/XEvent/core/XEObjectInfo.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | namespace Microsoft.SqlServer.Management.XEvent 5 | { 6 | 7 | /// 8 | /// interface for the child objects of Package 9 | /// 10 | public interface IXEObjectInfo 11 | { 12 | /// 13 | /// The name of the EventInfo 14 | /// 15 | string Name { get; } 16 | 17 | 18 | /// 19 | /// Gets the description. 20 | /// 21 | /// The description. 22 | string Description { get; } 23 | } 24 | 25 | } 26 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/XEvent/core/XEObjectInfoCollection.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | namespace Microsoft.SqlServer.Management.XEvent 5 | { 6 | internal interface IXEObjectInfoCollection where T : IXEObjectInfo 7 | { 8 | /// 9 | /// Gets the with the specified name. 10 | /// 11 | /// name of the Object 12 | /// Object with the specify name 13 | T this[string name] { get; } 14 | 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/XEventDbScoped/Constants.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | namespace Microsoft.SqlServer.Management.XEventDbScoped 5 | { 6 | internal class Constants 7 | { 8 | public static readonly string ModuleName = "DatabaseXEventObjectModel"; 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/XEventDbScoped/DatabaseSessionProvider.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | using System; 5 | using System.Globalization; 6 | using Microsoft.SqlServer.Management.Sdk.Sfc; 7 | using Microsoft.SqlServer.Management.XEvent; 8 | 9 | namespace Microsoft.SqlServer.Management.XEventDbScoped 10 | { 11 | /// 12 | /// Sql provider for Session at database scope 13 | /// 14 | internal class DatabaseSessionProvider : SessionProviderBase 15 | { 16 | public DatabaseSessionProvider(Session session) : base(session, "DATABASE") 17 | { 18 | } 19 | } 20 | } -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/XEventDbScoped/ProviderConstants.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | namespace Microsoft.SqlServer.Management.XEventDbScoped 5 | { 6 | internal static class ProviderConstants 7 | { 8 | public const string Create = "CREATE "; 9 | public const string Drop = "DROP "; 10 | public const string Alter = "ALTER "; 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/XEventDbScopedEnum/xml/MapValueInfo.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | mapvalues.map_key 16 | mapvalues.map_value 17 | 18 | 19 | 20 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/XEventDbScopedEnum/xml/XEStore.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | db_name() 14 | SERVERPROPERTY('servername') 15 | (SELECT count(*) FROM sys.dm_xe_database_sessions) 16 | 17 | 18 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/XEventDbScopedEnum/xml/inc_urn.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/XEventEnum/xml/EventInfo.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | objects.object_type = N'event' AND objects.package_guid = packages.guid AND (objects.capabilities & 1 = 0 OR objects.capabilities IS NULL) 5 | 6 | 7 | 8 | objects.name 9 | objects.description 10 | ISNULL(objects.capabilities, 0) 11 | objects.capabilities_desc 12 | 13 | 14 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/XEventEnum/xml/MapInfo.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | objects.object_type = N'map' AND objects.package_guid = packages.guid AND (objects.capabilities & 1 = 0 OR objects.capabilities IS NULL) 5 | 6 | 7 | 8 | objects.name 9 | objects.description 10 | ISNULL(objects.capabilities, 0) 11 | objects.capabilities_desc 12 | 13 | 14 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/XEventEnum/xml/MapValueInfo.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | mapvalues.name = objects.name and mapvalues.object_package_guid = objects.package_guid 5 | 6 | 7 | 8 | mapvalues.map_key 9 | mapvalues.map_value 10 | 11 | 12 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/XEventEnum/xml/TargetInfo.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | objects.object_type = N'target' AND objects.package_guid = packages.guid AND (objects.capabilities & 1 = 0 OR objects.capabilities IS NULL) 5 | 6 | 7 | 8 | objects.name 9 | objects.description 10 | ISNULL(objects.capabilities, 0) 11 | objects.capabilities_desc 12 | 13 | 14 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/XEventEnum/xml/TypeInfo.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | objects.object_type = N'type' AND objects.package_guid = packages.guid AND (objects.capabilities & 1 = 0 OR objects.capabilities IS NULL) 5 | 6 | 7 | 8 | objects.name 9 | objects.description 10 | objects.type_size 11 | ISNULL(objects.capabilities, 0) 12 | objects.capabilities_desc 13 | 14 | 15 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/XEventEnum/xml/XEStore.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | SERVERPROPERTY(N'ServerName') 13 | (SELECT count(*) FROM sys.dm_xe_sessions) 14 | 15 | 16 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/Management/XEventEnum/xml/inc_urn.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/SqlClrProvider/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. 2 | // Licensed under the MIT license. 3 | 4 | using System; 5 | using System.Security; 6 | 7 | // make code access security compatible with Netfx 2.0 8 | [assembly: SecurityRules(SecurityRuleSet.Level1)] 9 | [assembly: CLSCompliant(true)] 10 | -------------------------------------------------------------------------------- /src/Microsoft/SqlServer/SqlClrProvider/Microsoft.SqlServer.SqlClrProvider.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | $(NetfxVersion) 4 | $(MSBuildAllProjects);$(MSBuildThisFileFullPath) 5 | false 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | -------------------------------------------------------------------------------- /src/Microsoft/dirs.proj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /src/TestReferences.proj: -------------------------------------------------------------------------------- 1 | 2 | 3 | $(MSBuildAllProjects);$(MSBuildThisFileFullPath) 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /src/UnitTest/ConnectionInfo/Microsoft.SqlServer.Test.ConnectionInfoUnitTests.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | Microsoft.SqlServer.ConnectionInfoUnitTests 5 | $(TargetFrameworks) 6 | 0436;$(NoWarn) 7 | 8 | 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /src/UnitTest/Directory.Build.props: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | $(MSBuildAllProjects);$(MSBuildThisFileFullPath) 6 | $(NetfxVersion);net8.0 7 | false 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /src/UnitTest/Dmf/Microsoft.SqlServer.Test.DmfUnitTests.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | $(MSBuildAllProjects);$(MSBuildThisFileFullPath) 4 | $(TargetFrameworks) 5 | Microsoft.SqlServer.Test.DmfUnitTests 6 | {3AC096D0-A1C2-E12C-1390-A8335801FDAB};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC} 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | ExpressionTree_OperatorNodes.xml 15 | Designer 16 | 17 | 18 | -------------------------------------------------------------------------------- /src/UnitTest/Notebook/Microsoft.SqlServer.Test.SmoNotebookUnitTests.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | $(MSBuildAllProjects);$(MSBuildThisFileFullPath) 4 | $(TargetFrameworks) 5 | {3AC096D0-A1C2-E12C-1390-A8335801FDAB};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC} 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /src/UnitTest/RegSvrEnum/Microsoft.SqlServer.Test.RegSvrEnumUnitTests.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | $(MSBuildAllProjects);$(MSBuildThisFileFullPath) 4 | $(NetFxVersion) 5 | RegServerUnitTests 6 | {3AC096D0-A1C2-E12C-1390-A8335801FDAB};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC} 7 | 8 | 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /src/UnitTest/Sfc/Microsoft.SqlServer.Test.SfcUnitTests.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | $(MSBuildAllProjects);$(MSBuildThisFileFullPath) 4 | $(TargetFrameworks) 5 | Microsoft.SqlServer.Test.SfcUnitTests 6 | {3AC096D0-A1C2-E12C-1390-A8335801FDAB};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC} 7 | 8 | 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /src/UnitTest/Smo/Microsoft.SqlServer.Test.SmoUnitTests.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | $(MSBuildAllProjects);$(MSBuildThisFileFullPath) 4 | $(TargetFrameworks) 5 | Microsoft.SqlServer.Test.SmoUnitTests 6 | {3AC096D0-A1C2-E12C-1390-A8335801FDAB};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC} 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /src/UnitTest/SqlScriptPublish/Microsoft.SqlServer.Test.SqlScriptPublishTests.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | $(MSBuildAllProjects);$(MSBuildThisFileFullPath) 4 | $(TargetFrameworks) 5 | {3AC096D0-A1C2-E12C-1390-A8335801FDAB};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC} 6 | 7 | 8 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /src/UnitTest/XEventDbScoped/PredValueUnitTest.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft. 2 | // Licensed under the MIT license. 3 | 4 | using Microsoft.SqlServer.Management.XEvent; 5 | 6 | using Microsoft.VisualStudio.TestTools.UnitTesting; 7 | 8 | namespace Microsoft.SqlServer.Management.XEventDbScoped.UnitTests 9 | { 10 | /// 11 | /// Summary description for PredValueUnitTest 12 | /// 13 | [TestClass] 14 | public class PredValueUnitTest 15 | { 16 | /// 17 | /// Tests the string constructor. 18 | /// 19 | [TestMethod] 20 | [TestCategory("Unit")] 21 | public void TestStringConstructor() 22 | { 23 | PredValue value = new PredValue("abcdefg"); 24 | Assert.AreEqual("abcdefg", value.ToString()); 25 | value = new PredValue(""); 26 | Assert.AreEqual("", value.ToString()); 27 | } 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /src/UnitTest/dirs.proj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /src/dirs.proj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /src/tests.proj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | --------------------------------------------------------------------------------