NAME
ALTER FUNCTION - 修改一个函数的定义
SYNOPSIS
ALTER FUNCTION name ( [ type [, ...] ] ) RENAME TO newname
DESCRIPTION 描述
ALTER FUNCTION 修改一个函数的定义,目前***的功能是修改它的名字。
PARAMETERS 参数
- name
一个现有的函数的名字(可以有模式修饰)。- type
该函数参数的数据类型。- newname
函数的新名字。
EXAMPLES 例子
把名字为 sqrt,参数类型为 integer 的函数重命名为 square_root:
ALTER FUNCTION sqrt(integer) RENAME TO square_root;
COMPATIBILITY 兼容性
在 SQL 标准里有一个 ALTER FUNCTION 语句,但是它并没有提供重命名函数的选项。
SEE ALSO 参见
CREATE FUNCTION [create_function(7)], DROP FUNCTION [drop_function(l)]
#p#
NAME
ALTER FUNCTION - change the definition of a function
SYNOPSIS
ALTER FUNCTION name ( [ type [, ...] ] ) RENAME TO newname
DESCRIPTION
ALTER FUNCTION changes the definition of a function. The only functionality is to rename the function.
PARAMETERS
- name
- The name (optionally schema-qualified) of an existing function.
- type
- The data type of an argument of the function.
- newname
- The new name of the function.
EXAMPLES
To rename the function sqrt for type integer to square_root:
ALTER FUNCTION sqrt(integer) RENAME TO square_root;
COMPATIBILITY
There is an ALTER FUNCTION statement in the SQL standard, but it does not provide the option to rename the function.
SEE ALSO
CREATE FUNCTION [create_function(7)], DROP FUNCTION [drop_function(l)]