Fix to HQL to respect restriction on no prior ontology mapping.