'Executes the given SQL query and return an iterator over the rows.
With commit=True, automatically commits insert/update/delete changes.'

def execute(self, SQL, commit=False):

    self._query = SQL
    if (not SQL):
        return
    cursor = self._connection.cursor()
    cursor.execute(SQL)
    if (commit is not False):
        self._connection.commit()
    return self.RowsIterator(cursor)
