Article ID: 310373 - Last Review: May 13, 2007 - Revision: 2.7 The DataAdapter.Fill method does not set all of the properties of the DataTable and DataColumn objectsThis article was previously published under Q310373
This article refers to the following Microsoft .NET Framework Class Library namespace:
On This PageSYMPTOMS
After you use the DataAdapter.Fill method, various properties of the DataTable and DataColumn objects (such as primary keys, auto increment fields, nullable fields, unique indexes, and so on) are not set.
CAUSE
The DataAdapter object is optimized for read-only scenarios by default. The Fill method only retrieves the amount of schema that is necessary to display the data. You must take extra steps to obtain the additional schema that are necessary to update or validate an object.
RESOLUTION
To obtain additional information about the DataSet object, use one of the following methods:
310128
(http://support.microsoft.com/kb/310128/
)
When to use FillSchema and MissingSchemaAction
MORE INFORMATIONSteps to reproduce the behavior
REFERENCES
For more information on ADO.NET objects and syntax, see the following Microsoft .NET Framework Software Development Kit (SDK) documentation or MSDN Online:
Accessing Data with ADO.NET http://msdn2.microsoft.com/en-us/library/e80y5yhx(vs.71).aspx (http://msdn2.microsoft.com/en-us/library/e80y5yhx(vs.71).aspx) | Article Translations
|
Back to the top
