2

Guys, I have been surfing thru the web to find a way that I could use Multiple-Table-Inheritance in LINQ-To-SQL. But it looks like that it only supports single table inheritance which is not the best way to achieve inheritance in a ORM framework. I got to read that this will be addressed in next LINQ and Entity framework implementations. But how longer a stay we are talking about? In the meantime, if any of you guys have tried out a work-around implementation to achieve this, please let me know. And I thought of using my leisure time to come up with such an implementation so suggestions are welcome!

/Bumble Bee

3
  • I don't understand your comment "single table inheritance which is not the best way to achieve inheritance in a ORM framework". Could you explain further? Commented Nov 23, 2009 at 12:32
  • Its an opinion rather than a fact - but the problem with single table is that it can create a large table that is sparsley populated which is generally considered poor schema design Commented Nov 23, 2009 at 13:19
  • @Christian : Murph has cleared the doubt I guess. To elaborate more , when you have inheritance hierarchy mapped to a single table there will be lots of null values in rows instead of real data. Think that you have GenericProduct table which would map information about all the product types that would possibly in the application. Information related to one product would not be relevent to another product so some fields would have to be left blank. That is why it is not a good design practice. Commented Nov 23, 2009 at 16:14

1 Answer 1

1

Entity Framework supports table per type now: http://msdn.microsoft.com/en-us/library/bb399159.aspx

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.