def schema_exists(cls, cur, schema_name):
        """
        Check if schema exists
        """
        cur.execute("SELECT EXISTS (SELECT schema_name FROM information_schema.schemata WHERE schema_name = '{0}');"
                    .format(schema_name))
        return cur.fetchone()[0]
Check if schema exists