TechNet
Export (0) Print
Expand All

Database Methods

 

Namespace:   Microsoft.SqlServer.Management.Smo
Assembly:  Microsoft.SqlServer.Smo (in Microsoft.SqlServer.Smo.dll)

NameDescription
System_CAPS_pubmethodAlter()

Updates any Database object property changes on the instance of SQL Server. 

System_CAPS_pubmethodAlter(TerminationClause)

Updates any Database object property changes on the instance of SQL Server. 

System_CAPS_pubmethodAlter(TimeSpan)

Updates any Database object property changes on the instance of SQL Server. 

System_CAPS_pubmethodChangeMirroringState(MirroringOption)

Changes the mirroring configuration as specified by the options.

System_CAPS_pubmethodCheckAllocations(RepairType)

Scans all pages of the referenced database and tests pages to help ensure integrity.

System_CAPS_pubmethodCheckAllocationsDataOnly()

Scans all pages of the referenced database and tests only the data to help ensure integrity.

System_CAPS_pubmethodCheckCatalog()

Tests the integrity of the database catalog.

System_CAPS_pubmethodCheckIdentityValues()

Verifies the integrity of all identity columns in tables in the database.

System_CAPS_pubmethodCheckpoint()

Issues a checkpoint.

System_CAPS_pubmethodCheckTables(RepairType)

Tests the integrity of database pages for all tables and indexes defined on the tables of the database.

System_CAPS_pubmethodCheckTables(RepairType, RepairOptions)

Tests the integrity of database pages for all tables and indexes defined on the tables of the database.

System_CAPS_pubmethodCheckTables(RepairType, RepairOptions, RepairStructure, Nullable<Int64>)

System_CAPS_pubmethodCheckTables(RepairType, RepairStructure)

Tests the integrity of database pages for all tables and indexes defined on the tables of the database.

System_CAPS_pubmethodCheckTablesDataOnly()

Tests integrity of data in pages that store data for all tables and indexes defined on the tables of the referenced database.

System_CAPS_pubmethodCheckTablesDataOnly(RepairOptions)

Tests integrity of data in pages that store data for all tables and indexes defined on the tables of the referenced database, with the specified repair options.

System_CAPS_pubmethodCheckTablesDataOnly(RepairOptions, RepairStructure, Nullable<Int64>)

System_CAPS_pubmethodCheckTablesDataOnly(RepairStructure)

Tests integrity of data in pages that store data for all tables and indexes defined on the tables of the referenced database with the specified repair structure.

System_CAPS_pubmethodCreate()

Creates a database on the instance of SQL Server as defined by the Database object.

System_CAPS_pubmethodCreate(Boolean)

Creates a database on the instance of SQL Server as defined by the Database object.

System_CAPS_pubmethodDeny(DatabasePermissionSet, String)

Denies the specified set of permissions for the specified grantee on the database.

System_CAPS_pubmethodDeny(DatabasePermissionSet, String, Boolean)

Denies the specified set of permissions for the specified grantee and other users who the grantee granted the specified set of permissions on the database.

System_CAPS_pubmethodDeny(DatabasePermissionSet, String[])

Denies the specified set of permissions for the specified grantees on the database.

System_CAPS_pubmethodDeny(DatabasePermissionSet, String[], Boolean)

Denies the specified set of permissions for the specified grantees and other users who the grantee granted the specified set of permissions on the database.

System_CAPS_pubmethodDisableAllPlanGuides()

Disables all Plan Guides in a database.

System_CAPS_pubmethodDiscover()

Discovers a list of type Object.(Inherited from SqlSmoObject.)

System_CAPS_pubmethodDrop()

Drops the database.

System_CAPS_pubmethodDropAllPlanGuides()

Drops all Plan Guides in a database.

System_CAPS_pubmethodDropBackupHistory()

Drops the backup history for the database.

System_CAPS_pubmethodDropIfExists()

System_CAPS_pubmethodEnableAllPlanGuides()

Enables all Plan Guides in a database.

System_CAPS_pubmethodEnumBackupSetFiles()

Returns a DataTable listing files contained in a backup set.

System_CAPS_pubmethodEnumBackupSetFiles(Int32)

Returns a Data table that lists the files in a backup set.

System_CAPS_pubmethodEnumBackupSets()

Returns a DataTable listing the backup sets associated with a database.

System_CAPS_pubmethodEnumCandidateKeys()

Enumerates a list of all candidate primary keys in the database, which can be referenced by a foreign key.

System_CAPS_pubmethodEnumDatabasePermissions()

Enumerates a list of all permissions in the database.

System_CAPS_pubmethodEnumDatabasePermissions(DatabasePermissionSet)

Enumerates a list of permissions in the database for the specified permission set.

System_CAPS_pubmethodEnumDatabasePermissions(String)

Enumerates a list of permissions in the database for the specified user.

System_CAPS_pubmethodEnumDatabasePermissions(String, DatabasePermissionSet)

Enumerates a list of permissions in the database for the specified user and a specified permission set.

System_CAPS_pubmethodEnumLocks()

Enumerates a list of all current locks held on the database.

System_CAPS_pubmethodEnumLocks(Int32)

Enumerates a list of current locks held on the database for a specified system process ID.

System_CAPS_pubmethodEnumLoginMappings()

Enumerates a list of SQL Server logins for all the users in the database.

System_CAPS_pubmethodEnumMatchingSPs(String)

Enumerates a list of stored procedures that contain the specified string in the definition.

System_CAPS_pubmethodEnumMatchingSPs(String, Boolean)

Enumerates a list of stored procedures that contain the specified string in the definition.

System_CAPS_pubmethodEnumObjectPermissions()

Enumerates a list of permissions for objects in the database.

System_CAPS_pubmethodEnumObjectPermissions(ObjectPermissionSet)

Enumerates a list of permissions for objects in the database limited to the specified permission set.

System_CAPS_pubmethodEnumObjectPermissions(String)

Enumerates a list of permissions for objects in the database that belong to the specified user.

System_CAPS_pubmethodEnumObjectPermissions(String, ObjectPermissionSet)

Enumerates a list of permissions for objects in the database that belong to the specified user and limited to the specified permission set.

System_CAPS_pubmethodEnumObjects()

Enumerates a list of objects in the database.

System_CAPS_pubmethodEnumObjects(DatabaseObjectTypes)

Enumerates a list of objects in the database.

System_CAPS_pubmethodEnumObjects(DatabaseObjectTypes, SortOrder)

Enumerates a list of objects in the database.

System_CAPS_pubmethodEnumTransactions()

Enumerates a list of open transactions on the database.

System_CAPS_pubmethodEnumTransactions(TransactionTypes)

Enumerates a list of open transactions of a specified type on the database.

System_CAPS_pubmethodEnumWindowsGroups()

Enumerates a list of Windows groups.

System_CAPS_pubmethodEnumWindowsGroups(String)

Enumerates a list of Windows groups for a specified group.

System_CAPS_pubmethodEquals(Object)

(Inherited from Object.)

System_CAPS_pubmethodExecuteNonQuery(String)

Executes a statement in the context of the database where there are no results returned.

System_CAPS_pubmethodExecuteNonQuery(String, ExecutionTypes)

Executes a batch in the context of the database where there are no results returned for the specified execution type only.

System_CAPS_pubmethodExecuteNonQuery(StringCollection)

Executes a batch in the context of the database where there are no results returned.

System_CAPS_pubmethodExecuteNonQuery(StringCollection, ExecutionTypes)

Runs a collection of batches in the context of the database where there are no results returned for the specified execution type only.

System_CAPS_pubmethodExecuteWithResults(String)

Executes a collection of batches in the context of the database where there are results returned.

System_CAPS_pubmethodExecuteWithResults(StringCollection)

Executes a batch in the context of the database where there are results returned.

System_CAPS_protmethodFormatSqlVariant(Object)

Formats an object as T: Microsoft.Data.Schema.Sql.DataGenerator.SqlVariant type.(Inherited from SqlSmoObject.)

System_CAPS_protmethodGetContextDB()

Gets the context database that is associated with this object.(Inherited from SqlSmoObject.)

System_CAPS_protmethodGetDBName()

Gets the database name that is associated with the object.(Inherited from SqlSmoObject.)

System_CAPS_pubmethodGetHashCode()

(Inherited from Object.)

System_CAPS_protmethodGetPropValue(String)

Gets a property value of the SqlSmoObject object.(Inherited from SqlSmoObject.)

System_CAPS_protmethodGetPropValueOptional(String)

Gets a property value of the SqlSmoObject object.(Inherited from SqlSmoObject.)

System_CAPS_protmethodGetPropValueOptionalAllowNull(String)

Gets a property value of the SqlSmoObject object.(Inherited from SqlSmoObject.)

System_CAPS_pubmethodGetRemoteDataArchiveMigrationStatusReports(DateTime, Int32, String)

System_CAPS_pubmethodGetRemoteDatabaseMigrationStatistics()

System_CAPS_protmethodGetServerObject()

Gets the server of the SqlSmoObject object.(Inherited from SqlSmoObject.)

System_CAPS_pubmethodGetTransactionCount()

Gets the number of open transactions on the database.

System_CAPS_pubmethodGetTransactionCount(TransactionTypes)

Gets the number of open transactions of a specified type on the database.

System_CAPS_pubmethodGetType()

(Inherited from Object.)

System_CAPS_pubmethodGrant(DatabasePermissionSet, String)

Grants the specified set of permissions to the specified grantee on the database.

System_CAPS_pubmethodGrant(DatabasePermissionSet, String, Boolean)

Grants access to the specified permission to the grantee and the ability to grant access to other users on the database.

System_CAPS_pubmethodGrant(DatabasePermissionSet, String, Boolean, String)

Grants the specified set of permissions to the grantee and the ability to grant the set of permissions to other users on the database under an assumed role.

System_CAPS_pubmethodGrant(DatabasePermissionSet, String[])

Grants the specified set of permissions to the specified grantees on the database.

System_CAPS_pubmethodGrant(DatabasePermissionSet, String[], Boolean)

Grants access to the specified permission to the grantees and the ability to grant access to other users on the database.

System_CAPS_pubmethodGrant(DatabasePermissionSet, String[], Boolean, String)

Grants the specified set of permissions to the grantees and the ability to grant the set of permissions to other users on the database under an assumed role.

System_CAPS_pubmethodInitialize()

Initializes the object and forces the properties be loaded.(Inherited from SqlSmoObject.)

System_CAPS_pubmethodInitialize(Boolean)

Initializes the object and forces the properties be loaded.(Inherited from SqlSmoObject.)

System_CAPS_pubmethodIsMember(String)

Determines whether the specified group or role belongs to the database.

System_CAPS_protmethodIsObjectInitialized()

Verifies whether the object has been initialized.(Inherited from SqlSmoObject.)

System_CAPS_protmethodIsObjectInSpace()

Verifies whether the object is isolated or connected to the instance of SQL Server.(Inherited from SqlSmoObject.)

System_CAPS_pubmethodIsSupportedProperty(String)

(Inherited from SqlSmoObject.)

System_CAPS_pubmethodPrefetchObjects()

Prefetches database objects.

System_CAPS_pubmethodPrefetchObjects(Type)

Prefetches database objects of a specified type.

System_CAPS_pubmethodPrefetchObjects(Type, ScriptingOptions)

Prefetches database objects of a specified type with scripting options.

System_CAPS_pubmethodReauthorizeRemoteDataArchiveConnection(String)

System_CAPS_pubmethodRecalculateSpaceUsage()

Recalculates space usage.

System_CAPS_pubmethodRefresh()

Updates the Database object.(Overrides ScriptNameObjectBase.Refresh().)

System_CAPS_pubmethodRemoveFullTextCatalogs()

Removes full-text catalogs from the database.

System_CAPS_pubmethodRename(String)

Renames the database.

System_CAPS_pubmethodRevoke(DatabasePermissionSet, String)

Revokes a previously granted set of permissions from a grantee on the database.

System_CAPS_pubmethodRevoke(DatabasePermissionSet, String, Boolean, Boolean)

Revokes previously granted permissions from a grantee on the database and any other users to whom the grantee has granted the specified set of permissions. The grantee is also given the ability to revoke the specified set of permissions from other users under an assumed role.

System_CAPS_pubmethodRevoke(DatabasePermissionSet, String, Boolean, Boolean, String)

Revokes previously granted permissions from a grantee on the database and any other users to whom the grantee has granted the specified set of permissions. The grantee is also given the ability to revoke the specified set of permissions from other users under an assumed role.

System_CAPS_pubmethodRevoke(DatabasePermissionSet, String[])

Revokes a previously granted set of permissions from a list of grantees on the database.

System_CAPS_pubmethodRevoke(DatabasePermissionSet, String[], Boolean, Boolean)

Revokes previously granted permissions from grantees on the database and any other users to whom the grantees have granted the specified set of permissions. The grantees are also given the ability to revoke the specified set of permissions from other users under an assumed role.

System_CAPS_pubmethodRevoke(DatabasePermissionSet, String[], Boolean, Boolean, String)

Revokes previously granted permissions from grantees on the database and any other users to whom the grantees have granted the specified set of permissions. The grantees are also given the ability to revoke the specified set of permissions from other users under an assumed role.

System_CAPS_pubmethodScript()

Generates a Transact-SQL script that can be used to re-create the database.

System_CAPS_pubmethodScript(ScriptingOptions)

Generates a Transact-SQL script that can be used to re-create the database as specified by the script options.

System_CAPS_pubmethodSetDefaultFileGroup(String)

Sets the default file group for the database.

System_CAPS_pubmethodSetDefaultFileStreamFileGroup(String)

Sets the default filestream group.

System_CAPS_pubmethodSetDefaultFullTextCatalog(String)

Sets the default full-text catalog for the database.

System_CAPS_pubmethodSetOffline()

Sets the database offline.

System_CAPS_pubmethodSetOnline()

Sets the database online.

System_CAPS_pubmethodSetOwner(String)

Sets the database owner.

System_CAPS_pubmethodSetOwner(String, Boolean)

Sets the database owner.

System_CAPS_protmethodSetParentImpl(SqlSmoObject)

Sets the parent of the SqlSmoObject to the newParent parameter.(Inherited from SqlSmoObject.)

System_CAPS_pubmethodSetSnapshotIsolation(Boolean)

Sets the snapshot isolation level.

System_CAPS_pubmethodShrink(Int32, ShrinkMethod)

Shrinks the database.

System_CAPS_pubmethodToString()

Returns a String that represents the referenced object.(Inherited from SqlSmoObject.)

System_CAPS_pubmethodTruncateLog()

Truncates the database log.

System_CAPS_pubmethodUpdateIndexStatistics()

Updates index statistics.

System_CAPS_pubmethodValidate(String, Object[])

Validates the state of an object.(Inherited from SmoObjectBase.)

System_CAPS_pubmethodValidateAllPlanGuides()

Verifies the validity of the execution plans associated with the database.

System_CAPS_pubmethodValidateAllPlanGuides(DataTable)

Verifies the validity of the execution plans associated with the database and returns validation report.

NameDescription
System_CAPS_pubinterfaceSystem_CAPS_privmethodIAlienObject.Discover()

Discovers any dependencies.

Do not reference this member directly in your code. It supports the SQL Server infrastructure.(Inherited from SqlSmoObject.)

System_CAPS_pubinterfaceSystem_CAPS_privmethodIAlienObject.GetDomainRoot()

Returns the root of the domain.(Inherited from SqlSmoObject.)

System_CAPS_pubinterfaceSystem_CAPS_privmethodIAlienObject.GetParent()

Gets the parent of this object. Do not reference this member directly in your code. It supports the SQL Server infrastructure.(Inherited from SqlSmoObject.)

System_CAPS_pubinterfaceSystem_CAPS_privmethodIAlienObject.GetPropertyType(String)

Gets the type of the specified property.(Inherited from SqlSmoObject.)

System_CAPS_pubinterfaceSystem_CAPS_privmethodIAlienObject.GetPropertyValue(String, Type)

Gets the value of the specified property.(Inherited from SqlSmoObject.)

System_CAPS_pubinterfaceSystem_CAPS_privmethodIAlienObject.GetUrn()

Gets the Unified Resource Name (URN) of the object.

Do not reference this member directly in your code. It supports the SQL Server infrastructure.(Inherited from SqlSmoObject.)

System_CAPS_pubinterfaceSystem_CAPS_privmethodIAlienObject.Resolve(String)

Gets the instance that contains the information about the object from the Unified Resource Name (URN) of the object.(Inherited from SqlSmoObject.)

System_CAPS_pubinterfaceSystem_CAPS_privmethodIAlienObject.SetObjectState(SfcObjectState)

Sets the object state to the specified SfcObjectState value.(Inherited from SqlSmoObject.)

System_CAPS_pubinterfaceSystem_CAPS_privmethodIAlienObject.SetPropertyValue(String, Type, Object)

Sets the property value.(Inherited from SqlSmoObject.)

System_CAPS_pubinterfaceSystem_CAPS_privmethodISfcPropertyProvider.GetPropertySet()

Gets the interface reference to the set of properties of this object.

Do not reference this member directly in your code. It supports the SQL Server infrastructure.(Inherited from SqlSmoObject.)

Return to top
Show:
© 2016 Microsoft