VS2008 entity model omits some table columns while VS2010 does not - is this a framework issue? 3.5 vs 4.0? RRS feed

  • Question

  • In the diagram below you see that the Orders table and OrderDetail table are missing columns in the VS2008 Entity model but are not missing columns in the VS2010 Entity model.  And then in VS2010 -- it renames the Orders table to Order.  Is there something special about the Orders table?   Why are the columns missing in VS2008 but not VS2010?  Why did VS2010 Entity Model rename Orders to Order?  These are all straight forward tables with no triggers -- just relationships.  I only ask because I am relatively new to Entity Framework and just now getting my feet wet.  Thanks for any replies

    Rich P

    Friday, August 9, 2013 6:47 PM


  • I don't remember what version of the .NET Framework EF used on VS2008, but that version of EF would hide any property in a child object that is a pointer to the parent object.

    VS2008 version of EF, the Customer-ID in Customer is not going to be exposed as a property in Orders, which is a relationship property on the child object. At that time, I guess the reasoning was you were not suppose to do anything with the relationship property between parent and child object.

    Then I guess they thought better of hiding the property on the child object that ties it to a parent,  and they expose the relationship property in EF for VS2010. I think you can turn that feature on to expose those properties in the child objects at model creation on VS2010 version of EF. 

    Also there is option on VS2010 version of EF at model creation to pluralize an entity name on the model. VS2008 doesn't have the option. But I can't say that's your problem with that issue.  

    You can always go to the EDMX and make adjustments, which will be reflected on the model. 

    Saturday, August 10, 2013 5:23 PM