EnsureMappingsBuild is called in PersistenceModel.ImportProviders to pre... #258
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
I have to map a legacy database with the following (simplified) structure
ActiveRecord Root Table and Class
TypeInfo Child Table and Class with foreign key to ActiveRecord
MessageType Class that is also mapped to the TypeInfo table
As it is not possible to mix table per subclass and table per hierarchy in one inheritance tree,
I mapped TypeInfo to a view and made it a new root table. To accomplish this, a FluentMapping was used
in addition to the other automapped tables.
With the current FNH version this causes a DuplicateMapping exception as MessageType is also mapped as joined subclass of the ActiveRecord class.
I fixed that, calling EnsureMappingsBuild in PersistenceModel.ImportProviders.
I'm not sure if this is the exactly correct place - nevertheless all existing UTs succeed.