Ejemplo n.º 1
0
class IsTableExists(object):
    def __init__(self):
        self.execute = QuickExecuteGetListOneCol()

    def does_table_exist(self, db, table):
        """

        :param db:
        :param table:
        :return:
        """
        query = 'show tables in %s' % db
        tables = self.execute.quick_execute_get_list_one_col(db, query)
        return table in tables
Ejemplo n.º 2
0
 def __init__(self):
     self.execute = QuickExecuteGetListOneCol()