O'Reilly Forums: 2Nd Edition : Example 13-3 [Page 341] Throws An Exception - O'Reilly Forums
Page 1 of 1
2Nd Edition : Example 13-3 [Page 341] Throws An Exception
Posted 05 February 2013 - 12:11 AM
In the Creating POCO classes section [Chapter 13] example 13-3 on page 341 throws an exception at the following statements(in the Entities constructor)
_contacts = CreateObjectSet<Contact>();
_address = CreateObjectSet<Address>();
This is the exception I got:
MetadataException was unhandled
Schema specified is not valid. Errors:
The relationship 'PROGRAMMINGEFDB1Model.FK_Address_Contact' was not loaded because the type 'PROGRAMMINGEFDB1Model.Address' is not available.
The following information may be useful in resolving the previous error:
The required property 'addressID' does not exist on the type 'POCOTest.Address'.
Posted 02 December 2013 - 06:26 PM
I can't duplicate this problem. The 13-4 code that uses the 13-3 context runs as expected. The best suggestion I can make is download the chapter 13 sample from learnentityframework.com/downloads and compare to what you've got.
Share this topic:
Page 1 of 1
1 User(s) are reading this topic