class CASE
{
public virtual int ID
public virtual CASE_BUDGET Case_Budget
}
class CASE_BUDGET
{
public virtual int Case_Id;
}
class CASE_MAP
{
Id(x=>x.ID).GeneratedBy.Custom("trigger-identity");
HasOne<CASE_BUDGET>(x=>x.Case_Budget).Cascade.All();
}
class CASE_BUDGET_MAP
{
Id(x => x.Case_Id,"CASE_ID").GeneratedBy.Foreign("CASE");
}
I received unable to resolve property:CASE as my error message when I tried to save a case with a case budget in it.
Any help will be appreciated.
a
HasOnemapping always needs a corresponding property andReferencemapping on the other side (in you case CASE_BUDGET must have a Property referencing the Case). You have to specify it with.PropertyRef()or FNH will use the first property which type is of the mapped class.