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

Home -> Community -> Usenet -> c.d.o.server -> Re: OCI8 Perfomance Problem!

Re: OCI8 Perfomance Problem!

From: John Hatcher <jhatcher_at_uk.oracle.com>
Date: Wed, 02 Sep 1998 11:25:30 +0100
Message-ID: <35ED1D1A.98F42B2@uk.oracle.com>


George,

I've timed OCI8 using the following code:-

void dual()
{
  COCIStatement stmt(&s1);
  stmt = "select 1 from dual";
  int i;
  stmt.define_by_pos(1,i);
  for(int j = 0; j < 1000; j++)
  {
    stmt.execute();
  }
}

The times I get range from 0.791 to 0.821 secs.

Computer used: PII 300, 128MB RAM, Local 8.0.4 Oracle database.

Library used: ociwrap.lib (from
http://freespace.virgin.net/j.hatcher/ociwrap.htm )

George Mikeladze wrote:

> Hi ALL!
>
> DOES AnyOne Have Such Problem???:
>
> We have ported application from OCI7 to OCI8 - and there is significant
> slowdown!
>
> So I have done tests:
>
> 1) OCI7
> Execute "select 1 from dual" 1000 times using oexfet().
> oparse() was called only once.
> TIME=0.5 sec
>
> Oracle TRACE (tkprof) tells that Oracle8 Server took 0.5 sec to do this.
>
> 2) OCI8
> Execute "select 1 from dual" 1000 times using OCIStmtExecute() using iters
> parameter =1, so no more fetching is required.
> OCIStmtPrepare() was called only once.
> TIME=3 sec
>
> Oracle TRACE (tkprof) tells that Oracle8 Server took 0.5 sec to do this.
> SO WHERE ARE THAT 2.5 SECs???
>
> After tkprof-ing I found that oracle is parse-ing only once in both cases.
> But! repeating case 1) with OCI7 and parseing before each execute gives also
> 3 sec!
>
> We use same LIB and DLLs for both cases.
> Tests are run against local Oracle8.0.4 on WinNT4 on Dual PPro200+256Mb
> RAM+RAID.
>
> Thanks in forward!
> George Mikeladze.
Received on Wed Sep 02 1998 - 05:25:30 CDT

Original text of this message

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