1、在SQL语句中直接调用,如:
select sysdate from dual;
2、在PL/SQL代码中赋值给某个变量,如:
declare
dt date :=null;
begin
dt := sysdate;
...
end;
/
3、以上说的是Oracle内置函数,如果是自定义函数,则根据入口参数、出口参数的不同,调用方式不尽相同。
因为函数是有返回值的,所以要定义一个变量,可以这样
declare
xxx varchar2(100);
begin
xxx:=function;
end;