BUG: Error message when you try to obtain schema information from a SQL Server 2005 Mobile Edition database by using the SqlCeConnection.GetSchema method: "NotSupportedException" (912435)
The information in this article applies to:
- Microsoft SQL Server 2005 Mobile Edition
BUG #: 10895 (SQL Server CE)SQL Server CE:10895 SYMPTOMSConsider the following scenario: - You create a smart device project in Microsoft Visual Studio 2005.
- You try to obtain schema information from a Microsoft SQL Server 2005 Mobile Edition (SQL Server Mobile) database by using the SqlCeConnection.GetSchema method. For example, you try to obtain specific schema information about a column or about a table.
In this scenario, you receive the following error message: NotSupportedException This problem occurs when you use one of the following versions of the SqlCeConnection.GetSchema method: - SqlCeConnection.GetSchema(CollectionName)
- SqlCeConnection.GetSchema(CollectionName, RestrictionValues)
Note In these versions of the SqlCeConnection.GetSchema method, CollectionName is a placeholder for the schema name. RestrictionValues is a placeholder for a set of restriction values for the requested schema. CAUSEThis problem occurs because these versions of the SqlCeConnection.GetSchema method are not supported in SQL Server Mobile.WORKAROUNDTo work around this problem, you can obtain schema information about a data source by querying from the INFORMATION_SCHEMA views. For more information about the INFORMATION_SCHEMA views, see the "More Information" section.
Note You can also use the public properties of the SqlCeConnection object to obtain limited schema information about a data source. For example, you can use the Database property and the ServerVersion property.STATUS Microsoft has confirmed that this is a bug in the Microsoft products that are listed in the "Applies to" section.REFERENCESFor more information about the public properties of the SqlCeConnection object, visit the following Microsoft Developer Network (MSDN) Web site:
Modification Type: | Major | Last Reviewed: | 2/1/2006 |
---|
Keywords: | kbprb KB912435 kbAudDeveloper kbAudITPRO |
---|
|