Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.misc -> Re: Building a benchmark query
>>
I would like to take a Select query and change it have it return a measure
of the amount of time the it took to execute rather than the result set.
Does anyone have any suggestions of ways to do this? <<
SET TIMING ON Then run your query. A time value will automatically display (I believe it is in miiliseconds). Be sure to run the same query _at least_ twice. The first time will always be longer because the query needs to be parsed. Once it is parsed, it will run faster because it is executed in its parsed form from memory until you execute a different query (and this is case-sensitive). You should compare the initial values for each query to each other, and then compare the subsequent values for each query. I would repeat the entire process several times, as your "mileage" may vary depending on server conditions. Received on Thu Oct 28 1999 - 11:24:05 CDT