run time using table dual in centiseconds=896
run time using direct := in centiseconds=1007
-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf Of [EMAIL PROTECTED]
Sent: Tuesday, 23 April, 2002 9:23 PM
To: Multiple recipients of list ORACLE-L
Subject: RE: Currval and buffer getsWaleed/Kevin/Jonathan ...,
8.1.7.2 on HP-UX 64bit.
Modified version:declare
n1 number;
n2 number;
ss date;
begin
n1 := sys.dbms_utility.get_time;
for i in 1..100000 loop
select sysdate into ss from sys.x_$dual;
end loop;
n2 := sys.dbms_utility.get_time;
sys.dbms_output.put_line('run time using view x_$dual in centiseconds='||(n2-n1));
--
n1 := sys.dbms_utility.get_time;
for i in 1..100000 loop
select sysdate into ss from sys.dual;
end loop;
n2 := sys.dbms_utility.get_time;
sys.dbms_output.put_line('run time using table dual in centiseconds='||(n2-n1));
--
n1 := sys.dbms_utility.get_time;
for i in 1..100000 loop
ss := sysdate;
end loop;
n2 := sys.dbms_utility.get_time;
sys.dbms_output.put_line('run time using direct := in centiseconds='||(n2-n1));
end;Output:
run time using view x_$dual in centiseconds=1167
run time using table dual in centiseconds=1661
run time using direct := in centiseconds=339Alex.