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

Home -> Community -> Usenet -> c.d.o.misc -> Re: Fast execution of SQL queries

Re: Fast execution of SQL queries

From: Mark D Powell <mark.powell_at_eds.com>
Date: 12 Sep 2001 17:40:51 -0700
Message-ID: <178d2795.0109121640.4a4972fa@posting.google.com>


"F?ix" <fgaitero_at_e-netfinger.com> wrote in message news:<9no4os$bj3$1_at_talia.mad.ttd.net>...
> Hello, I'd like to know if there is a way
> to know the time of execution of a SQL query
> because I'm creating indexes and I want to
> know if they're going to be more efficient than not
> to use them in some queries.
> Thanks

From SQL*Plus you can use the timing command: set timing on Once you do this you will get the elapsed time for every SQL statement ran in the session.

There is also a set time command that will display the time, but why manually calculate the difference.

Inside pl/sql code you can select the time before and after SQL and calculate the difference.

You would need to run the test before adding the indexes, and then run the same SQL after adding the indexes. Do not forget to analyze after adding the indexes before running the tests.

Received on Wed Sep 12 2001 - 19:40:51 CDT

Original text of this message

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