This thread looks to be a little on the old side and therefore may no longer be relevant. Please see if there is a newer thread on the subject and ensure you're using the most recent build of any software if your question regards a particular product.
This thread has been locked and is no longer accepting new posts, if you have a question regarding this topic please email us at support@mindscape.co.nz
|
Hi there, I try to use the Mindscape.LightSpeed.MetaData.EntityInfo.FromType for a child class (LogoImage). That child class is a ConcreteTableInheritance from an abstract class (Image). The call to EntityInfo.FromType() fails with the error message "Descendent type [LogoImage] of type [Image] is not discriminated". ConcreteTableInheritance doesn't need a discriminator - right? At least there is no option at the designer to enter in one. As a repo use the model from http://www.mindscapehq.com/forums/thread/280804 Sörnt |
|
|
You're right, concrete table inheritance is not discriminated. We'll look into this and hopefully get you a fix soon. |
|
|
The following test passes for me using the "lsInsertOrderIssue.zip" model from the post you linked to:
I also tried it with our own suite of concrete table inheritance derived types, and it worked fine. We have been making some ongoing changes to concrete table inheritance support so it is possible the problem has already been fixed. Please check whether the error still occurs with a current nightly build. If so, please provide us with a minimal repro (just the two entity types involved) and we will have another go! |
|
|
I installed the current nightly (LightSpeed40Professional-20120326.msi) That is the code I use (assembly is the assembly where is Model is located):
Same error message. The exception is raised when the entityType is of "Image". |
|
|
Okay, the error occurs when you call Filter out abstract classes and you will be good to go:
|
|
|
Thanks for sorting that out! Consider to throw an suitable exception in that case. The error message right now is simple wrong. |
|