Search code examples
sql-server-cewindows-phone-7

Inheritance issues with SQL Server CE and Mango


I'm trying to implement SQL Server CE code in Windows Phone 7.1 (Mango). I have two classes, one base class and one inherited - both declared as [Table] with [Column]:s

Can you not have inheritance in SQL Server CE for Mango??

I don't want to change all my Entity classes to not have inheritance....

Might someone know the answer to this?


Solution

  • You can have inheritance in SQLCE for Mango if you follow the LINQ to SQL Inheritance Mapping pattern.

    I've blogged about the [Column] inheritance issue here and here. The LINQ to SQL Inheritance Mapping docs are here.