Just spent a number of hours trying to figure out why my Linq was not updating my foreign key when adding a record with a one-to-one relationship. Do not know if it is an issue or by design, but it took me a while to try the obvious....
Here is the simple tables I was using in this test:
Table Contacts
(
Contact_ID [int] IDENTITY(1,1) NOT NULL,
CreatedAt] [datetime] NOT NUL,
FullName [nvarchar](128) NOT NULL,
CONSTRAINT [PK_Contacts] PRIMARY KEY CLUSTERED
(
Contact_ID ASC
)
Table Comments
(
Comment_ID [int] IDENTITY(1,1) NOT NULL,
Contact_ID [int] NOT NULL,
LastEditedAt [datetime] NULL,
Comment [nvarchar](1024) NULL,
CONSTRAINT [PK_Comments] PRIMARY KEY CLUSTERED
(
[Comment_ID] ASC,
[Contact_ID] ASC
)
Table AdditionalInfo
(
Contact_ID [int]...