Col_G
asked on
Materialized view refresh - ORA-02019: connection description for remote database not found.
Please could you help me with an Oracle 9i materialized view issue.
I have materialized views setup on a laptop and a refresh group.
The database link is setup and working (tested via SQLPLUS select sysdate from dual@dblink)
However, the refresh hangs when run. I can see the session on the oracle server and it's displaying an error when running the statement for the first MV: -
ORA-02019: connection description for remote database not found.
Sorry if I haven't posted enough information - I am new to materialized view's!
We have another laptop which is setup the same way (as far as I can see) which refreshes fine!
Any assistance gratefully appreciated.
I have materialized views setup on a laptop and a refresh group.
The database link is setup and working (tested via SQLPLUS select sysdate from dual@dblink)
However, the refresh hangs when run. I can see the session on the oracle server and it's displaying an error when running the statement for the first MV: -
ORA-02019: connection description for remote database not found.
Sorry if I haven't posted enough information - I am new to materialized view's!
We have another laptop which is setup the same way (as far as I can see) which refreshes fine!
Any assistance gratefully appreciated.
the owner of the materialized view needs to own the database link or the link needs to be public.
ASKER
Hi,
Thank you for your reply, I have checked the link & it's a public link.
All the posts I found seem to point to the link but I have checked & double checked this & appears correct. Is there anything else i can try?
Thank you for your reply, I have checked the link & it's a public link.
All the posts I found seem to point to the link but I have checked & double checked this & appears correct. Is there anything else i can try?
there must be something else that isn't being seen
can you post the exact query you used and the results of
select * from dba_db_links
can you post the exact query you used and the results of
select * from dba_db_links
In the materialized view creation, are you using FORCE or FAST?
ASKER
We are using FAST.
The results of SELECT * FROM DBA_DB_LINKS are in the attached file DBLinks.txt.
The MV's and Refresh Group are owned by user CAL.
As there are 3 DB Links will it default to the one owned by CAL or use the Public view?
When I tested the links I logged in as both SYS and MVADMIN and ran: -
SELECT SYSDATE FROM DUAL@SDIR.GEMCO.LOCAL
Both returned the date
Thank you for your assistance.
DBLinks.txt
The results of SELECT * FROM DBA_DB_LINKS are in the attached file DBLinks.txt.
The MV's and Refresh Group are owned by user CAL.
As there are 3 DB Links will it default to the one owned by CAL or use the Public view?
When I tested the links I logged in as both SYS and MVADMIN and ran: -
SELECT SYSDATE FROM DUAL@SDIR.GEMCO.LOCAL
Both returned the date
Thank you for your assistance.
DBLinks.txt
FAST vs COMPLETE vs FORCE is irrelevant for the error you are getting
It will use the one owned by CA. What happens when you test using CAL?
What is the MV query?
It will use the one owned by CA. What happens when you test using CAL?
What is the MV query?
ASKER
The laptop is temp unavailable so I'll test the CAL link tomorrow but the MV Query is as follows: -
SELECT "CONFIRMED", "DATE_BOOKED", "DATE_PROPOSED", "DATE_COMPLETE", "PRINTED", "CANCELED", "CANCEL_REASON", "CONFIRMED_WITH", "CONFIRMED_DATE", "CREATE_USER", "CREATE_DATE_TIME", "EQUIPMENT_DUE_FROM", "EQUIPMENT_DUE_TO", "SCHEDULE_ID", "NUMBER_OF_ITEMS", "CANCELLED_BY", "CANCELLED_DATE", "CUSTOMER_ORDER_NUMBER", "COMMENTS_TEMP", "COMMENTS", "CALL_ID", "JOB_SHEET", "ENGINEER_ID", "DATE_DUE", "CALL_TYPE", "CUSTOMER_ID", "COMPLETE" FROM "CAL"."CALLS"@SDIR.GEMCO.L OCAL
When I ran the refresh and checked the sessions on the Oracle server I could see the session which was trying to execute this statement. It was this sessions that displayed the ORA-02019 error.
The session was showing the following as the current SQL...
SELECT /*+ */ "A2"."CONFIRMED","A2"."DAT E_BOOKED", "A2"."DATE _PROPOSED" ,"A2"."DAT E_COMPLETE ","A2"."PR INTED","A2 "."CANCELE D","A2"."C ANCEL_REAS ON","A2"." CONFIRMED_ WITH","A2" ."CONFIRME D_DATE","A 2"."CREATE _USER","A2 "."CREATE_ DATE_TIME" ,"A2"."EQU IPMENT_DUE _FROM","A2 "."EQUIPME NT_DUE_TO" ,"A2"."SCH EDULE_ID", "A2"."NUMB ER_OF_ITEM S","A2"."C ANCELLED_B Y","A2"."C ANCELLED_D ATE","A2". "CUSTOMER_ ORDER_NUMB ER","A2"." COMMENTS", "A2"."CALL _ID","A2". "JOB_SHEET ","A2"."EN GINEER_ID" ,"A2"."DAT E_DUE","A2 "."CALL_TY PE","A2"." CUSTOMER_I D","A2"."C OMPLETE"," A1"."CHANG E_VECTOR$$ " FROM "CAL"."CALLS" "A2", ( (SELECT DISTINCT "A5"."CALL_ID" "CALL_ID","A5"."CHANGE_VEC TOR$$" "CHANGE_VECTOR$$" FROM "CAL"."MLOG$_CALLS" "A5" WHERE "A5"."SNAPTIME$$">:1 AND "A5"."DMLTYPE$$"<>'D')UNIO N (SELECT "A4"."CALL_ID" "CALL_ID","A4"."CHANGE_VEC TOR$$" "CHANGE_VECTOR$$" FROM "CAL"."USLOG$_CALLS"@! "A4" WHERE "A4"."DMLTYPE$$"<>'I')) "A1" WHERE "A2"."CALL_ID"="A1"."CALL_ ID" ORDER BY "A2"."CALL_ID"
Hope this helps
SELECT "CONFIRMED", "DATE_BOOKED", "DATE_PROPOSED", "DATE_COMPLETE", "PRINTED", "CANCELED", "CANCEL_REASON", "CONFIRMED_WITH", "CONFIRMED_DATE", "CREATE_USER", "CREATE_DATE_TIME", "EQUIPMENT_DUE_FROM", "EQUIPMENT_DUE_TO", "SCHEDULE_ID", "NUMBER_OF_ITEMS", "CANCELLED_BY", "CANCELLED_DATE", "CUSTOMER_ORDER_NUMBER", "COMMENTS_TEMP", "COMMENTS", "CALL_ID", "JOB_SHEET", "ENGINEER_ID", "DATE_DUE", "CALL_TYPE", "CUSTOMER_ID", "COMPLETE" FROM "CAL"."CALLS"@SDIR.GEMCO.L
When I ran the refresh and checked the sessions on the Oracle server I could see the session which was trying to execute this statement. It was this sessions that displayed the ORA-02019 error.
The session was showing the following as the current SQL...
SELECT /*+ */ "A2"."CONFIRMED","A2"."DAT
Hope this helps
ASKER
Hi,
I have logged into SQLPlus as user CAL and run: -
select sysdate from dual@sdir.gemco.local which returned the SYSDATE OK.
I then removed the public link and re-ran the above which returned ORA-02019: connection description for remote database not found.
I dropped the CAL DB Link and recreated with username & passsword for CAL and the correct service_name. I re-ran the select script which returned the SYSDATE.
I then ran the Refresh group (still logged in as CAL) exec dbms_refresh.refresh('CAL_ UPDATE') but it appears to hang and it creates no session on the main oracle server.
Any more ideas?
Regards,
Col
I have logged into SQLPlus as user CAL and run: -
select sysdate from dual@sdir.gemco.local which returned the SYSDATE OK.
I then removed the public link and re-ran the above which returned ORA-02019: connection description for remote database not found.
I dropped the CAL DB Link and recreated with username & passsword for CAL and the correct service_name. I re-ran the select script which returned the SYSDATE.
I then ran the Refresh group (still logged in as CAL) exec dbms_refresh.refresh('CAL_
Any more ideas?
Regards,
Col
what is the wait event for the hung session?
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Provided my own work around to the problem.
Root cause of the initials issue was never found.
Root cause of the initials issue was never found.