Table Per Hierarchy problems
Posted: Wed 28 Oct 2015 09:36
Hello,
I have a database model with a base class and two classes that inherit from this base class. I want this to be a Table Per Hierarchy inheritance. Creating this model works fine. The inheritance discriminator is an int. The base class condition and derived class conditions are all provided. But when I use model -> Update Database From Model, and check the Regenerate Storage, the discriminator is not added to the Table. When I dont use Regenerate Storage, the discriminator is added to the Table though.
Also, when I make the base class Abstract, it is not added at all to the Database at all, wich is a problem, because the base class in this model should be abstract.
How can I solve this problem?
Thanks in advance
Martin
I have a database model with a base class and two classes that inherit from this base class. I want this to be a Table Per Hierarchy inheritance. Creating this model works fine. The inheritance discriminator is an int. The base class condition and derived class conditions are all provided. But when I use model -> Update Database From Model, and check the Regenerate Storage, the discriminator is not added to the Table. When I dont use Regenerate Storage, the discriminator is added to the Table though.
Also, when I make the base class Abstract, it is not added at all to the Database at all, wich is a problem, because the base class in this model should be abstract.
How can I solve this problem?
Thanks in advance
Martin