tag:blogger.com,1999:blog-8643450826744932654.post7704391871430442514..comments2023-10-05T08:33:57.392-07:00Comments on The Senile Coder: NHibernate: One-to-One Mapping With Shared KeyChrishttp://www.blogger.com/profile/07050959395523812736noreply@blogger.comBlogger2125tag:blogger.com,1999:blog-8643450826744932654.post-83425588153572688672013-04-10T19:04:50.233-07:002013-04-10T19:04:50.233-07:00UserDetail represented an existing table which cou...UserDetail represented an existing table which could not be altered for reasons beyond the developer's control.<br /><br />I hadn't tested it, but it probably could have had the x.Unique(true) to the ComposedId. Since we were dealing with a 1:1 ratio anyway, the parent table's Id was enforcing the unique constraint anyway.Chrishttps://www.blogger.com/profile/07050959395523812736noreply@blogger.comtag:blogger.com,1999:blog-8643450826744932654.post-22854357904483424852013-04-04T08:35:58.009-07:002013-04-04T08:35:58.009-07:00Great post. Is there a reason not to add a Id for ...Great post. Is there a reason not to add a Id for UserDetail table. Shouldn't it add a line of x.Unique(true) to ComposedId to make the row unique.ping ponghttps://www.blogger.com/profile/14625032024505356391noreply@blogger.com