Telerik Forums RSShttps://www.telerik.com/urn:uuid:4ec61b11-8ca9-4055-9cb5-85dbf41ce54bhttps://www.telerik.com/forums/permalink/ERvGTqmMVUCctYXb9BzlSwAdding Association to Sub-ClassHi Zoran,<br />
<br />
Ah, I see - I had wondered how the 'Default' option actually works, thanks for explaining! And I see what you mean about the relational editor as well, that makes sense.<br />
<br />
Thanks for your help and prompt response.<br />
<br />
Thanks,<br />
<br />
J.urn:uuid:8371bb9b-c21f-4321-9dce-d3b6d0de15b5https://www.telerik.com/forums/permalink/m7txgx_CIUOdztO20N4VtQAdding Association to Sub-ClassHello Jamie,
<p>If you just choose 'Default' in this case, you should be able to proceed without problems during runtime. The OpenAccess runtime automatically finds the primary key property of the corresponding class and relates the foreign key of "d" &nbsp;to that primary key. The other way to achieve more precise definition during design time would be, if you have your tables defined, to use the relational view of the association editor where you could chose the correct column of the "b" table. That is however, not necessary for scenarios where you have a single id field declared in the base class.</p>
Kind regards,<br />
Zoran <br />
the Telerik team
<div class="forumBaloonTop"></div>
<div class="forumBaloon">OpenAccess ORM Q2'12 Now Available! Get your hands on all the <a href="http://www.telerik.com/products/orm/whats-new.aspx">new stuff</a>.
</div>
<div class="forumBaloonBottom"></div>urn:uuid:0ed958e7-53e6-4fe7-ad68-db127d5456b8https://www.telerik.com/forums/permalink/51jZDuZT50-taNsSfVRWuAAdding Association to Sub-ClassHi,<br />
<br />
I currently have a vertical hierarchy for three classes a -&gt; b -&gt; c. The hierarchy seems to model correctly using vertical inheritance, a primary 'ID' property added to (a). When I want to add an association for a separate table (lets call it d!) to an inherited table (in this case b) I can't reference the primary ID field in the drop down list of the association editor - all the local properties for b are listed, but none from a, specifically not the primary key that I need.<br />
<br />
From earlier posts, it appears that this ought to be possible, but I can't see an obvious mechanism. Am I missing something here?!<br />
<br />
Thanks,<br />
<br />
J.