change inheritance strategy to @Inheritance(strategy=InheritanceType.JOINED)
fixed named query