Can anyone tell me how (fluent-nh or otherwise) to map a one-to-one
relationship that is not based off of the primary key of the  table.

I have the following schema:

Item
----
id_col //primary key
plinid // this is the unique fk column

ProductLineItem
plinid // primary key

No matter what I do, NH tries to join Item and LineItem with ic_col field,
when I need it to use plinid

My current mapping for the One-One is:
HasOne(x =>
x.LineItem).WithForeignKey("FK_icitem_icPlin").PropertyRef(p=>p.ProductLineId);

Sorry to post here, I tried the nhusers group but got no response.

Thanks,
John

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Fluent NHibernate" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/fluent-nhibernate?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to