Re: What exception catching methods should be used with Pro*C?

From: Ramon F Herrera <ramon_at_conexus.net>
Date: Sun, 22 Nov 2009 13:31:14 -0800 (PST)
Message-ID: <9eb36f45-3d55-4f68-9923-f103d553fd08_at_g27g2000yqn.googlegroups.com>



On Nov 22, 3:55 pm, hpuxrac <johnbhur..._at_sbcglobal.net> wrote:
> On Nov 22, 10:47 am, Ramon F Herrera <ra..._at_conexus.net> wrote:
>
> snip
>
> > I have doubts about the error handling methods to be applied. I am
> > trying to figure out how to catch any error while the Pro*C code is
> > being executed and to pass them upstream to the C++ layer. I must add
> > that the application is a never-ending server and therefore it must
> > not crash or even "exit()" upon failure.
>
> Umm ... what will your app do if the database it is connected to shuts
> down?

I used the term "connected" loosely. I am not using a connectionoriented  protocol. Only when my server receives a request, it will attempt to make a query to the Oracle server.

So, so answer your question, my app/server will simply say:

"The database is not available"

Without crashing or stopping.

-Ramon Received on Sun Nov 22 2009 - 15:31:14 CST

Original text of this message