'Check if table exists
>>> hh = HiveMetastoreHook()
>>> hh.table_exists(db=\'airflow\', table_name=\'static_babynames\')
True
>>> hh.table_exists(db=\'airflow\', table_name=\'does_not_exist\')
False'

def table_exists(self, table_name, db='default'):

    try:
        t = self.get_table(table_name, db)
        return True
    except Exception as e:
        return False
