Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> Re: Remote database
>>>>> "Hillar" == Hillar Vetik <hillar_at_medisoft.ee> writes:
Hillar> Hello, how to check remote datatabase is up or down, link Hillar> exist & if remote database is up all work fine, but if remote Hillar> database is down i have big timeout & some meory problems Hillar> Hill
I had a similar situation and this is how I handled it.
I created a package which has functions for creating and dropping database links plus a pfunction to test the link is working. There are probably better ways of doing this, but I just attempt to do a
select sysdate from dual_at_LINK
I put some exection handlers in the function - if I succeed in getting the date from the remote system, the function returns true, else it returns false.
This may not get around the timouts as you may still be waiting for this select, but at least you can check for a valid link before launching into the part of your application which is attempting to process data over the link and I find it easier to handle this condition before rather than just putting exception handlers around the procedures/functions which need to access the remote db (of course, you still need these as the link can go down at anytime).
Tim
-- Tim Cross The e-mail address on this message is FALSE (obviously!). My real e-mail is to a company in Australia called rapttech and my login is tcross - if you really need to send mail, you should be able to work it out!Received on Tue Feb 11 2003 - 23:26:43 CST
![]() |
![]() |