

def test_nextset(self):
    from warnings import warn
    con = self._connect()
    try:
        cur = con.cursor()
        if (not hasattr(cur, 'nextset')):
            return
        try:
            self.executeDDL1(cur)
            sql = self._populate()
            for sql in self._populate():
                sql.execute(sql)
            self.help_nextset_setUp(cur)
            cur.callproc('deleteme')
            numberofrows = cur.fetchone()
            assert (numberofrows[0] == len(self.samples))
            assert cur.nextset()
            names = cur.fetchall()
            assert (len(names) == len(self.samples))
            s = cur.nextset()
            if s:
                empty = cur.fetchall()
                self.assertEquals(len(empty), 0, 'non-empty result set after other result sets')
        finally:
            self.help_nextset_tearDown(cur)
    finally:
        con.close()

dataset/ETHPy150Open cloudera/hue/desktop/core/ext-py/MySQL-python-1.2.5/tests/test_MySQLdb_dbapi20.py test_MySQLdb.test_nextset/VarMisuse@81/96 `cur`->`sql`