I'm still working on my Entity Framework fluency... I have a class which contains 3 nullable ints and I want to ensure that explicitly 1 of these 3 properties have a value at any given time. How do I achieve this ?
[key]
public int primary {get; set;}
public int? Id1 { get; set; } <-- this
public int? Id2 { get; set; } <-- this
public int? Id3 { get; set; } <-- this
I think I need to create a clustered index? (I'm honestly unsure)
Also, I am using a MySql database, in-case that is relevant.