Pablo Castro, Britt Johnston, Michael Pizzo: ADO.NET Entity Framework - One Year Later
Aug 30, 2007 at 9:19 PMUpon further inspection I have also noticed a few issues where the Linq to SQL makes more sense.
For example, adding and deleting data.
The context.AddObject() and context.DeleteObject() need the entity set name passed as a string which means that the value can't be checked at compile time (actually, I am getting a exception about the Type not existing or something right now.)
The Linq to SQL has a more natural approach which uses a simple Add and Remove on the (in the L2SQL case) table.
So the L2SQL looks like
context.TableName.Add(object); ![]()
whereas the EF looks like
context.AddObject("EntitySetName", object); ![]()
which in my opinion is not very nice.
I am curious why the design decision and would like to know if there are any plans to go to a design that is more like Linq to SQL especially since EF already knows about the mappings?
Cheers,
Clint