I have a parent class with some column definition and different child class to inherit the column definition and some extra column. However, I can't get it to work. The create table call always fail.
[Table]
class Parent
{
[column] public int ID;
[column] public string Name;
}
[Table]
class Child : Parent
{
[column] public string ChildAttrib;
}
using (var db = new DataConnection())
{
db.CreateTable<Child>();
}
Here is the error message:
Message: FirebirdSql.Data.FirebirdClient.FbException : Dynamic SQL Error
SQL error code = -104
Token unknown - line 16, column 2
Row
----> FirebirdSql.Data.Common.IscException : Dynamic SQL Error
SQL error code = -104
Token unknown - line 16, column 2
Row
How do I solve it? I found some InheritanceMapping but I have no idea what this is use for and whether it can apply to my code or not. I just want to have a parent class define a set of common column and have a child class to inherit it and define extra column.