Import of EDMX file results in "foreign key...not being enforced"

Discussion of open issues, suggestions and bugs regarding Entity Developer - ORM modeling and code generation tool
Post Reply
billster6809
Posts: 29
Joined: Mon 27 Jan 2014 21:08

Import of EDMX file results in "foreign key...not being enforced"

Post by billster6809 » Mon 27 Jan 2014 21:16

I am trying to import an existing EDMX file in Entity Developer. It reports an error for two entity types. I have a base "StorageLocation" type. From that, there is a derived "RackStorage" type. From that, I have "RackGrid" and "RackDiamond" derived types.

I get the following errors, which I could not find described in the help. The edmx has no problems in VisualStudio 2012 or 2013, and the generated classes work just fine as they are currently being created from the edmx (inheritance chain is properly enforced). The errors, although they reference the RackStorage type, actually result in the error 'x' on the base class StorageLocation.

Can you tell me how to address these errors so that I can complete the conversion? If you need the edmx file to evaluate, I can provide it; just tell me where it goes.

1 Problem in mapping fragments starting at lines 877, 888:The foreign key 'Foreign key constraint 'FK_RackDiamond_inherits_RackStorage' from table StorageLocations_RackDiamond (Id) to table StorageLocations_RackStorage (Id):' is not being enforced in the model. An Association or inheritance relationship needs to be created to enforce this constraint.
D:\Tmp\WineDataModel.edml

2 Problem in mapping fragments starting at lines 877, 883:The foreign key 'Foreign key constraint 'FK_RackGrid_inherits_RackStorage' from table StorageLocations_RackGrid (Id) to table StorageLocations_RackStorage (Id):' is not being enforced in the model. An Association or inheritance relationship needs to be created to enforce this constraint.
D:\Tmp\WineDataModel.edml

Shalex
Site Admin
Posts: 8248
Joined: Thu 14 Aug 2008 12:44

Re: Import of EDMX file results in "foreign key...not being enforced"

Post by Shalex » Tue 28 Jan 2014 12:10

billster6809 wrote:If you need the edmx file to evaluate, I can provide it; just tell me where it goes.
Please specify the exact version (x.x.xxx) of your Entity Developer and send us your *.edmx file.

billster6809
Posts: 29
Joined: Mon 27 Jan 2014 21:08

Re: Import of EDMX file results in "foreign key...not being enforced"

Post by billster6809 » Tue 28 Jan 2014 18:57

Information sent via email as requested, including the edmx file.
Version is the current one, 5.78.276 (just purchased a day ago)

Shalex
Site Admin
Posts: 8248
Joined: Thu 14 Aug 2008 12:44

Re: Import of EDMX file results in "foreign key...not being enforced"

Post by Shalex » Thu 30 Jan 2014 11:55

Thank you for the test model. We are investigating the issue.

Shalex
Site Admin
Posts: 8248
Joined: Thu 14 Aug 2008 12:44

Re: Import of EDMX file results in "foreign key...not being enforced"

Post by Shalex » Wed 12 Feb 2014 12:16

The bug with parsing inheritances in *.edmx is fixed. We will notify you when the corresponding build of Entity Developer is available for download.

Shalex
Site Admin
Posts: 8248
Joined: Thu 14 Aug 2008 12:44

Re: Import of EDMX file results in "foreign key...not being enforced"

Post by Shalex » Thu 13 Feb 2014 16:35

New build of Entity Developer 5.7.296 is available for download!
It can be downloaded from http://www.devart.com/entitydeveloper/download.html (trial version) or from Registered Users' Area (for users with active subscription only).
For more information, please refer to http://forums.devart.com/viewtopic.php?f=32&t=28929.

billster6809
Posts: 29
Joined: Mon 27 Jan 2014 21:08

Re: Import of EDMX file results in "foreign key...not being enforced"

Post by billster6809 » Thu 13 Feb 2014 21:00

I confirm that 5.7.296 resolves the import issue. EDMX file is now successfully imported into Entity Developer with no errors.

Thank you for excellent support!

Post Reply