System.Data.Common 命名空间

System.Data.Common 命名空间包含由 .NET Framework 数据提供程序共享的类。 The System.Data.Common namespace contains classes shared by the .NET Framework data providers.

DataAdapter

表示用于填充 DataSet 和更新数据源的一组 SQL 命令和一个数据库连接。Represents a set of SQL commands and a database connection that are used to fill the DataSet and update the data source.

DataColumnMapping

包含从 DataAdapter 继承的对象的一般列映射。Contains a generic column mapping for an object that inherits from DataAdapter. 此类不能被继承。This class cannot be inherited.

DataColumnMappingCollection

包含 DataColumnMapping 对象的集合。Contains a collection of DataColumnMapping objects.

DataRecordInfo

提供对 DbDataRecord 的结构类型相关信息以及列信息的访问。Provides access to information about the structural type and column information for a DbDataRecord.

DataTableMapping

包含有关源表与 DataTable 之间映射关系的说明。Contains a description of a mapped relationship between a source table and a DataTable. 填充 DataSet 时,由 DataAdapter 使用该类。This class is used by a DataAdapter when populating a DataSet.

DataTableMappingCollection

DataTableMapping 对象的集合。A collection of DataTableMapping objects. 此类不能被继承。This class cannot be inherited.

DbColumn

表示数据源中的列。Represents a column within a data source.

DbCommand

表示要对数据源执行的 SQL 语句或存储过程。Represents an SQL statement or stored procedure to execute against a data source. 为表示命令的、数据库特有的类提供一个基类。Provides a base class for database-specific classes that represent commands. ExecuteNonQueryAsync

DbCommandBuilder

自动生成用于协调 DataSet 的更改与关联数据库的单表命令。Automatically generates single-table commands used to reconcile changes made to a DataSet with the associated database. 这是一个只能被继承的抽象类。This is an abstract class that can only be inherited.

DbCommandDefinition

定义可缓存的命令计划。Defines a cacheable command plan.

DbConnection

定义数据库连接的核心行为,并为数据库专用连接提供基类。Defines the core behavior of database connections and provides a base class for database-specific connections.

DbConnectionStringBuilder

提供强类型化连接字符串生成器的基类。Provides a base class for strongly typed connection string builders.

DbDataAdapter

帮助实现 IDbDataAdapter 接口。Aids implementation of the IDbDataAdapter interface. DbDataAdapter 的继承类实现了一组功能以提供强类型,但是继承了完全实现 DataAdapter 所需的大部分功能。Inheritors of DbDataAdapter implement a set of functions to provide strong typing, but inherit most of the functionality needed to fully implement a DataAdapter.

DBDataPermission

启用一个 .NET Framework 数据提供程序,以帮助确保用户具有足够的安全级别来访问数据。Enables a .NET Framework data provider to help ensure that a user has a security level adequate for accessing data.

DBDataPermissionAttribute

将某安全操作与自定义安全特性相关联。Associates a security action with a custom security attribute.

DbDataReader

从数据源中读取行的只进流。Reads a forward-only stream of rows from a data source.

DbDataReaderExtensions

此类包含用于 DbDataReader 的列架构扩展方法。This class contains column schema extension methods for DbDataReader.

DbDataRecord

实现 IDataRecordICustomTypeDescriptor,并为 DbEnumerator 提供数据绑定支持。Implements IDataRecord and ICustomTypeDescriptor, and provides data binding support for DbEnumerator.

DbDataSourceEnumerator

提供了一种枚举本地网络内的所有可用数据库服务器实例的机制。Provides a mechanism for enumerating all available instances of database servers within the local network.

DbEnumerator

公开 GetEnumerator() 方法,该方法支持 .NET Framework 数据提供程序对集合进行简单的迭代。Exposes the GetEnumerator() method, which supports a simple iteration over a collection by a .NET Framework data provider.

DbException

代表数据源引发的所有异常的基类。The base class for all exceptions thrown on behalf of the data source.

DbMetaDataCollectionNames

提供用于已知的 MetaDataCollections 的常数列表:DataSourceInformation、DataTypes、MetaDataCollections、ReservedWords 和 Restrictions。Provides a list of constants for the well-known MetaDataCollections: DataSourceInformation, DataTypes, MetaDataCollections, ReservedWords, and Restrictions.

DbMetaDataColumnNames

提供静态值,这些值用于 DataTable 中包含的 MetaDataCollection 对象的列名称。Provides static values that are used for the column names in the MetaDataCollection objects contained in the DataTable. DataTable 由 GetSchema 方法创建。The DataTable is created by the GetSchema method.

DbParameter

表示 DbCommand 的参数,还可表示该参数到一个 DataSet 列的映射。Represents a parameter to a DbCommand and optionally, its mapping to a DataSet column. 有关参数的详细信息,请参阅配置参数和参数数据类型For more information on parameters, see Configuring Parameters and Parameter Data Types.

DbParameterCollection

DbCommand 相关的参数集合的基类。The base class for a collection of parameters relevant to a DbCommand.

DbProviderConfigurationHandler

任何提供程序都可使用此类以支持特定于提供程序的配置部分。This class can be used by any provider to support a provider-specific configuration section.

DbProviderFactories

表示一组静态方法,这些方法用于创建 DbProviderFactory 类的一个或多个实例。Represents a set of static methods for creating one or more instances of DbProviderFactory classes.

DbProviderFactoriesConfigurationHandler

此类型支持 .NET Framework 基础结构,不能在代码中直接使用。This type supports the .NET Framework infrastructure and is not intended to be used directly from your code.

DbProviderFactory

表示一组方法,这些方法用于创建提供程序对数据源类的实现的实例。Represents a set of methods for creating instances of a provider's implementation of the data source classes.

DbProviderManifest

所有 CLR 类型 types 的元数据接口。Metadata Interface for all CLR types types.

DbProviderServices

用于生成命令定义的工厂;用该对象的类型作为程序提供工厂中的 IServiceProvider.GetService 方法参数;The factory for building command definitions; use the type of this object as the argument to the IServiceProvider.GetService method on the provider factory;

DbProviderSpecificTypePropertyAttribute

标识在设置提供程序特定的类型时,使用强类型参数类中的哪个提供程序特定的属性。Identifies which provider-specific property in the strongly typed parameter classes is to be used when setting a provider-specific type.

DbTransaction

定义数据库事务的核心行为,并为数据库专用事务提供基类。Defines the core behavior of database transactions and provides a base class for database-specific transactions.

DbXmlEnabledProviderManifest

表示基于 XML 定义实现 DbProviderManifest 的基类。Represents a base class that implements the DbProviderManifest based on an XML definition. 您可以使用 DbXmlEnabledProviderManifest 类在运行时获取特定于提供程序的信息。You can use the DbXmlEnabledProviderManifest class to obtain provider-specific information at runtime.

EntityRecordInfo

提供对实体元数据的访问。Provides access to entity metadata.

RowUpdatedEventArgs

为 .NET Framework 数据提供程序的 RowUpdated 事件提供数据。Provides data for the RowUpdated event of a .NET Framework data provider.

RowUpdatingEventArgs

为 .NET Framework 数据提供程序的 RowUpdating 事件提供数据。Provides the data for the RowUpdating event of a .NET Framework data provider.

SchemaTableColumn

描述数据库表的架构的列元数据。Describes the column metadata of the schema for a database table.

SchemaTableOptionalColumn

描述数据库表的架构的可选列元数据。Describes optional column metadata of the schema for a database table.

结构

FieldMetadata

提供对 DataRecordInfo 对象的字段元数据的访问。Provides access to field metadata for a DataRecordInfo object.

接口

IDbColumnSchemaGenerator

生成列架构。Generates a column schema.

枚举

CatalogLocation

指示目录名称在文本命令的限定表名中的位置。Indicates the position of the catalog name in a qualified table name in a text command.

GroupByBehavior

指定 GROUP BY 子句中的列与 SELECT 语句的选择列表中的非聚合列之间的关系。Specifies the relationship between the columns in a GROUP BY clause and the non-aggregated columns in the select-list of a SELECT statement.

IdentifierCase

指定在搜索系统目录时,数据源如何处理标识符。Specifies how identifiers are treated by the data source when searching the system catalog.

SupportedJoinOperators

指定数据源支持何种类型的 Transact-SQL 联接语句。Specifies what types of Transact-SQL join statements are supported by the data source.

注解

.Net Framework 数据提供程序描述一组类,这些类用于访问托管空间中的数据源,如数据库。A .NET Framework data provider describes a collection of classes used to access a data source, such as a database, in the managed space. 受支持的提供程序包括:用于 ODBC 的 .NET Framework 数据提供程序,用于 OLEDB 的 .NET Framework 数据提供程序,用于 Oracle 的 .NET Framework 数据提供程序和用于 SQL Server 的 .NET Framework 数据提供程序。Supported providers include the .NET Framework Data Provider for ODBC, the .NET Framework Data Provider for OLEDB, the .NET Framework Data Provider for Oracle, and the .NET Framework Data Provider for SQL Server. System.Data.Common 中的类旨在为开发人员提供一种方法,以编写适用于所有 .NET Framework 数据提供程序的 ADO.NET 代码。The classes in System.Data.Common are intended to give developers a way to write ADO.NET code that will work against all .NET Framework data providers.

有关如何使用.net Framework 进行编程时使用此命名空间的概念信息,请参阅编写使用 ADO.NET 提供程序独立代码For conceptual information about how to use this namespace when programming with the.NET Framework, see Writing Provider Independent Code with ADO.NET.