---
name: "ALTER_SCHEMA"
section: "7"
platform: "linux"
package: "postgresql"
version: "18.6-4"
release: "Arch Linux 2026-11-01"
platforms: ["linux"]
url: "https://new.carta.tech/ALTER_SCHEMA"
---

# ALTER\_SCHEMA(7)

change the definition of a schema

## NAME

ALTER\_SCHEMA - change the definition of a schema

## SYNOPSIS

```
ALTER SCHEMA name RENAME TO new_name
ALTER SCHEMA name OWNER TO { new_owner | CURRENT_ROLE | CURRENT_USER | SESSION_USER }
```

## DESCRIPTION

**ALTER SCHEMA** changes the definition of a schema.

You must own the schema to use **ALTER SCHEMA**. To rename a schema you must also have the CREATE privilege for the database. To alter the owner, you must be able to SET ROLE to the new owning role, and that role must have the CREATE privilege for the database. (Note that superusers have all these privileges automatically.)

## PARAMETERS

*name*

The name of an existing schema.

*new\_name*

The new name of the schema. The new name cannot begin with pg\_, as such names are reserved for system schemas.

*new\_owner*

The new owner of the schema.

## COMPATIBILITY

There is no **ALTER SCHEMA** statement in the SQL standard.

## SEE ALSO

CREATE SCHEMA ([**CREATE\_SCHEMA**(7)](/CREATE_SCHEMA/7.md)), DROP SCHEMA ([**DROP\_SCHEMA**(7)](/DROP_SCHEMA/7.md))
