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

Home -> Community -> Mailing Lists -> Oracle-L -> Re: Checking if remote database is up

Re: Checking if remote database is up

From: stephen booth <stephenbooth.uk_at_gmail.com>
Date: Tue, 26 Apr 2005 15:26:21 +0100
Message-ID: <687bf9c405042607264362359f@mail.gmail.com>


On 4/26/05, Niall Litchfield <niall.litchfield_at_gmail.com> wrote:
> Would a quick hack to code the procedure as a version of

>=20

> declare
> l_alive number;
> begin
> select 1 into l_alive from dual_at_remotedb;
> if l_alive =3D 1 then
> proc_name;
> end if
> end;
> /
>=20

> make sense?
>=20

> This might avoid ocella upgrades breaking your check, or dealing with
> the politics :).

Yes, that looks like it will do the job nicely.

>=20

> Alternatively you might wish to add error handling for what ever
> errors you get when the ocella db is down and add that to your
> functions and procedures...

Unfortunately the app just fires dynamic SQL directly at the database, no functions or procedures involved. I'm told by the consultants that they can add some code to call a function and check the result. I suspect packaging that block up in a function that returns TRUE if it works and adding an exception handler for the ORA-03113 error which returns FALSE would do quite nicely.

Thanks

Stephen

--=20
It's better to ask a silly question than to make a silly assumption.

--
http://www.freelists.org/webpage/oracle-l
Received on Tue Apr 26 2005 - 10:31:00 CDT

Original text of this message

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