-
ora-23401
I am trying to execute a snapshot refresh from a batch script for the first time.
I keep getting a Refresh Error : ORA-23401: materialized view "WCD3A_DWH"."WCD3A_OPEN_CUST_CLOCK"
does not exist"
How do I resolve this? I believe way to correct this is that I need to enter the snapshot in the snapshot table?? If so, how do I do this?
See script below.
$ORACLE_HOME/bin/sqlplus.exe -S wcd3a_dwh/????xxxx@sso2dwhp << EOF >> ${GENERAL_LOG}
set serveroutput on size 100000 time on timing on
set echo on verify on
begin
dbms_mview.refresh('WCD3A_CLOSE_CUST_CLOCK','C');
dbms_output.put_line('Refresh OK');
exception
when others then
dbms_output.put_line('Refresh Error : '||sqlerrm);
end;
/
-
did you try the status of the Materialized view?.
Thanks,
Thanigaivasan.
-
Not quite sure what you are referring to? Please explain. Thank you.
-
dbms_mview.refresh('WCD3A_CLOSE_CUST_CLOCK','C');
Refresh Snapshot with Reference of schema name i.e.
dbms_mview.refresh(wcd3a_dwh.WCD3A_CLOSE_CUST_CLOCK','C');
-
Yes.. As you can see from my original message, this is what I am doing and thats when I get the error,
-
:confused:
I don't see in your script that that you are qualifying the name of the snapshot with the schema name.
dbms_mview.refresh('wcd3a_dwh.WCD3A_CLOSE_CUST_CLOCK','C');