System.Data.MissingSchemaAction Enumeration

Specifies the action to take when adding data to the System.Data.DataSet and the required System.Data.DataTable or System.Data.DataColumn is missing.


public enum MissingSchemaAction


The System.Data.MissingSchemaAction values are used whenever an action is taken that could change the schema of the System.Data.DataSet.


Member NameDescription

Adds the necessary columns to complete the schema.


Adds the necessary columns and primary key information to complete the schema. For more information about how primary key information is added to a System.Data.DataTable, see IDataAdapter.FillSchema(DataSet, SchemaType).To function properly with the .NET Framework Data Provider for OLE DB, AddWithKey requires that the native OLE DB provider obtains necessary primary key information by setting the DBPROP_UNIQUEROWS property, and then determines which columns are primary key columns by examining DBCOLUMN_KEYCOLUMN in the IColumnsRowset. As an alternative, the user may explicitly set the primary key constraints on each System.Data.DataTable. This ensures that incoming records that match existing records are updated instead of appended. When using AddWithKey, the .NET Framework Data Provider for SQL Server appends a FOR BROWSE clause to the statement being executed. The user should be aware of potential side effects, such as interference with the use of SET FMTONLY ON statements. See SQL Server Books Online for more information.


An InvalidOperationException is generated if the specified column mapping is missing.


Ignores the extra columns.


Namespace: System.Data
Assembly: System.Data (in System.Data.dll)
Assembly Versions: 1.0.3300.0, 1.0.5000.0,