How to use the aiomysql.cursors function in aiomysql

To help you get started, we’ve selected a few aiomysql examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github aio-libs / aiomysql / tests / test_dictcursor.py View on Github external
def test_ssdictcursor(self):
        conn = self.conn
        c = yield from conn.cursor(aiomysql.cursors.SSDictCursor)
        yield from c.execute("SELECT * from dictcursor where name='bob'")
        r = yield from c.fetchall()
        self.assertEqual([self.bob], r,
                         "fetch a 1 row result via fetchall failed via "
                         "DictCursor")