# phpman > man > ALTER_STATISTICS(7)

ALTER [STATISTICS(7)](https://www.chedong.com/phpMan.php/man/STATISTICS/7/markdown)                PostgreSQL 14.23 Documentation                ALTER [STATISTICS(7)](https://www.chedong.com/phpMan.php/man/STATISTICS/7/markdown)



## NAME
       ALTER_STATISTICS - change the definition of an extended statistics object

## SYNOPSIS
       ALTER STATISTICS _name_ OWNER TO { _new_owner_ | CURRENT_ROLE | CURRENT_USER | SESSION_USER }
       ALTER STATISTICS _name_ RENAME TO _new_name_
       ALTER STATISTICS _name_ SET SCHEMA _new_schema_
       ALTER STATISTICS _name_ SET STATISTICS _new_target_

## DESCRIPTION
       **ALTER** **STATISTICS** changes the parameters of an existing extended statistics object. Any
       parameters not specifically set in the **ALTER** **STATISTICS** command retain their prior settings.

       You must own the statistics object to use **ALTER** **STATISTICS**. To change a statistics object's
       schema, you must also have CREATE privilege on the new schema. To alter the owner, you must
       also be a direct or indirect member of the new owning role, and that role must have CREATE
       privilege on the statistics object's schema. (These restrictions enforce that altering the
       owner doesn't do anything you couldn't do by dropping and recreating the statistics object.
       However, a superuser can alter ownership of any statistics object anyway.)

## PARAMETERS
       _name_
           The name (optionally schema-qualified) of the statistics object to be altered.

       _new_owner_
           The user name of the new owner of the statistics object.

       _new_name_
           The new name for the statistics object.

       _new_schema_
           The new schema for the statistics object.

       _new_target_
           The statistic-gathering target for this statistics object for subsequent **ANALYZE**
           operations. The target can be set in the range 0 to 10000; alternatively, set it to -1 to
           revert to using the maximum of the statistics target of the referenced columns, if set,
           or the system default statistics target (default_statistics_target). For more information
           on the use of statistics by the PostgreSQL query planner, refer to Section 14.2.

## COMPATIBILITY
       There is no **ALTER** **STATISTICS** command in the SQL standard.

## SEE ALSO
       CREATE STATISTICS (**CREATE**___**[STATISTICS**(7)](https://www.chedong.com/phpMan.php/man/STATISTICS/7/markdown)), DROP STATISTICS (**DROP**___**[STATISTICS**(7)](https://www.chedong.com/phpMan.php/man/STATISTICS/7/markdown))



PostgreSQL 14.23                                2026                             ALTER [STATISTICS(7)](https://www.chedong.com/phpMan.php/man/STATISTICS/7/markdown)
