I have a custom class that has an implicit conversion with string. I'm using POCO classes in c# with EF6.0 and I'd like to be able to declare a property like this:
[Column("TABLE_COLUMN_NAME", TypeName = "char")]
public virtual CustomClass ClassColumnName { get; set; }
Then have entity framework just assign the value taking advantage of the implicit conversion. However when I try to run this code I get an error like Error 3002: Problem in mapping fragments
. CustomClass
has an implicit conversion operator setup for both going to and coming from string but it appears that EF wants to treat the whole type as if it were a table and fails the mapping. Any guidance would be appreciated.