点击(此处)折叠或打开
-
set serveroutput on
-
declare
-
v_num number := &sv_num;
-
v_result number;
-
begin
-
v_result := power(v_num,2);
-
dbms_output.put_line('The value of v_result is:'||v_result);
-
end;
- /
set serveroutput on :启用dbms_output.put_line语句
power(x,y) :计算x^y次方,返回。