@classmethod
    def count(cls, where, *args):
        '''
        Find by 'select count(*) from where ... ' and return one and only one result.
        '''
        return select_int('select count(%s) from %s %s' % (cls.__primary_key__.name, cls.__table__, where), *args) if where else \
               select_int((cls.__primary_key__.name, cls.__table__) % 'select count(%s) from %s')
dataset/ETHPy150Open michaelliao/transwarp/transwarp/db.py/Model.count/swapped operands of `%`