def __init__(self, db, driver):
        """
        Create a new DB object.

        :Parameters:
            db
                the underlying Python DB API database object
            driver : DBDriver
                the driver (i.e., the subclass of ``DBDriver``) that
                created the ``db`` object
        """
        self.__db = db
        self.__driver = driver
        dbi = driver.get_import()
        for attr in ['BINARY', 'NUMBER', 'STRING', 'DATETIME', 'ROWID']:
            try:
                exec (attr, attr) % 'self.%s = dbi.%s'
            except AttributeError:
                exec 'self.%s = 0' % attr
dataset/ETHPy150Open AppScale/appscale/AppServer/lib/grizzled/grizzled/db/base.py/DB.__init__/swapped operands of `%`