I have setup my classes like below. Hibernate ddl generates 2 tables Admin and Customer. I would have expected only one table as per the SINGLE_TABLE strategy.
@MappedSuperclass
public abstract class BaseUser{
...
}
@Entity
@Inheritance(strategy=InheritanceType.SINGLE_TABLE)
public class Admin extends BaseUser{
...
}
@Entity
@Inheritance(strategy=InheritanceType.SINGLE_TABLE)
public class Customer extends BaseUser{
@OneToMany
private List<Order> orders;
...
}