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

Home -> Community -> Usenet -> c.d.o.tools -> Re: running c++ program within database

Re: running c++ program within database

From: <davidchantf_at_hotmail.com>
Date: Fri, 01 Jun 2001 15:41:50 GMT
Message-ID: <2JOR6.1277$Zy.1232642@newsrump.sjc.telocity.net>

Hi,
 I am using oracle ODBC 8.01.72, VC++ 6.0 on winnt 4.0. I have one operation that needs about 20*x database access, where x can be from 5 to 30.
 I can set up the program and database in one computer, but still slow. Right now I only have hundreds of records for testing, but in production mode, it can grow to millions of records.  And the table design is complex and highly normailized.  I never try to use PL/SQL, Is it a much better choice than ODBC ? Do I need to rewrite my program at all ?
 Thanks.
David

wayne <no_at_email.please.com> wrote:
>> I have a C++ program that need to make a lot of database access within  one

>> operation, which is very slow. So I am wondering if I can run this program
>> inside database? so to reduce the number of database access, and increase
>> performance.
 

> First of all, you would need to access the database anyway, regardless of
> whether it's running on the database or outside.
 

> Now, as far as performance optimization, there are lots of things you could
> do: Server-side tweaks as well as client-side... you can also scrutinize the
> design of both the server and the overall process...
 

> In answer to your question, I have never seen a C++ program be part of the
> database itself. You can call out from the PL/SQL to the C++, but the C++
> would have to be an external module (and may have to have a C wrapper,
> possibly), as in a DLL or SO file.
 

> What would I do at this point if I were you (and I _have_ been in your
> situation before)? I would start with the overall design. Minor tweaks do
> not help if the underlying design is bad. I would then move on to
> optimizing the server and the client code (and what I would do depends
> heaviliy on what the exact tasks are and how long each takes to run).
 

> If you describe your project more we can help more (ie. what operations are
> being dome that take a long time, how many records are we talking about,
> what platform you run in, whether or not you are already running the program
> on the same machine as the server, etc...).
Received on Fri Jun 01 2001 - 10:41:50 CDT

Original text of this message

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