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
|
When using Single Table Inheritance, is there a way to not have to specify the Value in the discriminator attribute? If I'm using an Id in my table to denote the type, the values can't be gauranteed to never change between environments (ie. dev, qa, production). It would mean a recompile if the values did indeed change. Make sense? Any thoughts would be appreciated. Thanks again! |
|
|
Unfortunately this is not currently supported -- the discriminator value is stored in an attribute and therefore has to be compiled in. I have logged a feature request for this. The workaround for now is to use a surrogate key, which can be controlled as part of the data rather than allocated by the database -- though this isn't as convenient if you want to traverse the association of course. |
|
|
Good deal. Thanks! |
|