def METHOD_NAME(self, sql, select=True):
    self._cur.METHOD_NAME(sql)
    if select:
        while True:
            result = self._cur.fetchone()
            if result:
                yield result
            else:
                break
    else:
        result = self._cur.fetchall()
        return result