Connecting Tech Pros Worldwide Help | Site Map

oracle - program around ora-02068 error ??

  #1  
Old June 26th, 2009, 11:31 PM
Newbie
 
Join Date: Jun 2009
Posts: 1
How to program around ora-02068 error

On DB2 side, newbie to oracle platform. . .HELP !!

Oracle procedure, db link to DB2, gets 02068 rpc disconnect errors inconsistently/randomly, each require manual resub for correction. No error messages, no contention, and response time on both platforms are OK.

procedure:

1. select....
2. commit.
3. execute immediate...alter session...close dblink...
4. exception

We think it is getting stuck between 1 and 2 above, problems in communications, just hanging so exceptions do not catch errors. Theory is the next invoke generates the error message when it tries to reuse the hanging link, before it starts a new one. (?)

Question: How can we program a band-aid to check the elapsed response time, interrupt and return control after 10 elapsed seconds, so we can retry and/or terminate cleanly as appropriate ??

Thanks.
  #2  
Old July 11th, 2009, 01:02 AM
Newbie
 
Join Date: Dec 2008
Posts: 9

re: oracle - program around ora-02068 error ??


try testing the connection first before going to step 2 :

you should enter into infinite loop (or until defined time) until connection replies ...

try something like this :

declare
v_c number := 0;
begin
loop
begin
select 1 into v_c from dual where rownum = 1 @(db_link);

if v_c = 1 then exit ; end if;

exception when no_data_found then null ;
end;
end loop;
end ;
Reply

Tags
ora 02068, oracle, program, rpc disconnect


Similar Threads
Thread Thread Starter Forum Replies Last Post
Oracle 7.3 v 9.2 client connection problems Tig answers 4 June 27th, 2008 08:00 PM
Connecting Windows Clients to Oracle Wayne Happ answers 1 June 27th, 2008 06:44 PM
Oracle Adventures Chris Botha answers 13 November 20th, 2005 12:03 AM
Connecting Windows Clients to Oracle Wayne Happ answers 1 July 19th, 2005 10:28 PM
ORA-00904: invalid column name Shino answers 8 July 19th, 2005 09:59 PM