Use WITH not WHERE in HQL