Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Mailing Lists -> Oracle-L -> RE: Currval and buffer gets

RE: Currval and buffer gets

From: <Alexander.Feinstein_at_mitchell1.com>
Date: Tue, 23 Apr 2002 18:23:21 -0800
Message-ID: <F001.0044D350.20020423182321@fatcity.com>


Waleed/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=339

Alex.

--

Please see the official ORACLE-L FAQ: http://www.orafaq.com
--

Author:
  INET: Alexander.Feinstein_at_mitchell1.com

Fat City Network Services    -- (858) 538-5051  FAX: (858) 538-5051
San Diego, California        -- Public Internet access / Mailing Lists

--------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message
to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing). Received on Tue Apr 23 2002 - 21:23:21 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US