• Post Reply Bookmark Topic Watch Topic
  • New Topic

How to implement OneToOne Unidirectional when revers has foreign key

 
Chaminda Amarasinghe
Ranch Hand
Posts: 413
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Falks,

I think this question would be a vary common situation.

Lets say I have an existing db tables as follows,




But I want an OOP implementation as inverse of relational. That means Employee refers to an instance of Cubicle but Cubical has no reference to Employee.



How can I achieve this? (I dont want bidirectional relationship)

Open to discuss.

Thanks
 
Sergio Tridente
Ranch Hand
Posts: 329
Java Linux Oracle
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You can't.
 
Chaminda Amarasinghe
Ranch Hand
Posts: 413
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Very Bad
 
What are you doing? You are supposed to be reading this tiny ad!
the new thread boost feature brings a LOT of attention to your favorite threads
https://coderanch.com/t/674455/Thread-Boost-feature
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!