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: Oracle and Dotnet

Re: Oracle and Dotnet

From: Jim Kennedy <kennedy-downwithspammersfamily_at_attbi.net>
Date: Thu, 2 Jun 2005 17:51:05 -0700
Message-ID: <JoydnbBJ-9ijNALfRVn-rw@comcast.com>

"Larry" <larry_at_larry.com> wrote in message news:qOLne.9857$xm3.5416_at_attbi_s21...
> pobox002_at_bebub.com wrote:
> > You are not using bind variables and over parsing. Each time you build
> > that string it is a unique statement that needs validating and
> > compiling.
> >
> > You should have something like
> >
> > string SQL = "insert into test values (?)";
> >
> > and bind the placeholder. Sorry I am not a C# programmer so I don't
> > have the syntax, but there should be ODP.NET code examples on
> > http://otn.oracle.com
> >
>
>
> Thanks for that reply. I changed my string to
>
> =============================================
> string SQL = "insert into test values ('1')";
> =============================================
>
> By doing that I removed the variable and simply deposited a constant.
> My performance did improve from 35 to 40 inserts per second but that is
> still way short of any usable rate for my application.
>
> Thanks again!

Larry,
You are not using bind variables. This is very very inefficient. You are forcing a hard parse. Use bind variables and just reexecute. Also I suspect the odp.net isn't set up correctly. I don't use odp.net so I can't tell you what to change. I have used Oracle's ole objects in VB and C++ and using bind variables and array interface in VB I can get around 20,000 records inserted per sec into an IOT table. (over the network), with 8.1.7.4 version of Oracle. (10g should be more efficient)

Jim Received on Thu Jun 02 2005 - 19:51:05 CDT

Original text of this message

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