"countQueryTripes(sparqlQuery) > 0" is probably adequate.