Replaces fetchObject(s) with findBySql where possible.