views:

264

answers:

2

Does Visual Studio 2008 SP1 / .NET 3.5 support Linq to Entities (ADO.NET Entity Data Model / edmx) with SQL Server 2008 R2? Specifically, the hierarchy id type? If so, do you have a download link, if not is there a published date when this feature will become available? I experimented a bit today after installing GDR R2 to support Sql 2k8 dbproj and the AdventureWorks2008 import failed.

EDIT: thanks devio, I found this by clicking through

Note: EF 1.0 Compatibility Issues The Entity Framework team would like us to let you know that AdventureWorks2008 is a little bit ahead of the curve in terms of the Katmai features it uses. Some datatypes in AdventureWorks2008 (such as hierarchyid and geometry) are not supported in the entity framework, and some datatypes like date and time can cause problems. The workaround is to exclude tables like Production.Document from your model if possible since there is currently no support for the hierarchyid datatype in Entity Framework 1.0. Unfortunately the Entity Framework tooling which updates your model from the database will pull in tables like Production.Document even if they were specifically excluded when the model was created, so use of that feature on AdventureWorks2008 is not supported at this time. We look forward to a follow-on release of Entity Framework which has full Katmai type support.

Any word on when the next version of EF is available?

+1  A: 

In a word, no, not HIERARCHYID.

I don't know if it will be in v4.

Craig Stuntz
+1  A: 

MSDN says:

New data types introduced in SQL Server 2008 are not supported explicitly by this version of the Entity Framework. These data types include the following: hierarchyid, geography, and filestream. Because the AdventureWorks 2008 database features these new data types, errors occur when generating a data model that is based on the AdventureWorks 2008 database.

(which is kind of funny considering AdventureWorks does implement new server features which the development tools do NOT support)

devio