| In mongodb, for example, the following mapping:
@Entity
@Inheritance(strategy = InheritanceType.SINGLE_TABLE)
@DiscriminatorColumn(name = "type")
public abstract class BigEvent implements Serializable {
}
should create the following index (or something similar):
> db.BigEvent.getIndexes()
[
...
{
"v" : 1,
"key" : {
"type" : 1
},
"name" : "type_idx",
"ns" : "ogm_test_database.BigEvent"
}
]
This should also happen with the deafult column (DTYPE column). |