More generic error raised on empty query