Jena needs parentheses in HAVING clause