Use connector buildWhere for count() i