??? 今天在看Oracle官方文档时,发现了or replace的一个重要作用。?之前在该函数上赋予的权限使用or replace时,可以不同再次赋予。? 即:使用or replace时,其它用户在该函数上的权限不会丢失和变化。
?
Specify OR
REPLACE
to re-create the function if it already exists. Use this clause to change the definition of an existing function without dropping, re-creating, and regranting object privileges previously granted on the function. If you redefine a function, then Oracle Database recompiles it.
Users who had previously been granted privileges on a redefined function can still access the function without being regranted the privileges.
If any function-based indexes depend on the function, then Oracle Database marks the indexes DISABLED
.
?