Can you use the same Enum in multiple entities in Linq-to-SQL?

Posted by Mark on Stack Overflow See other posts from Stack Overflow or by Mark
Published on 2010-03-09T11:50:37Z Indexed on 2010/03/09 11:51 UTC
Read the original article Hit count: 149

Filed under:
|
|

In my persistence layer, I've declared a load of Enums to represent tables containing reference data (i.e. data never changes).

In Linq2SQL, I am able to set the type of an entity property to an enum type and all is well, but as soon as I set a second entity's property to use the same enum type, the Code Generator (MSLinqToSQLGenerator) start generating an empty code file.

I assume that MSLinqToSQLGenerator is quietly crashing. The question is why, and are there any work-arounds? Anyone else experienced this problem?

© Stack Overflow or respective owner

Related posts about linq-to-sql

Related posts about enums