Home » SQL & PL/SQL » SQL & PL/SQL » Metrialized View exceptions
Metrialized View exceptions [message #268449] Tue, 18 September 2007 12:47 Go to next message
pkirangi
Messages: 74
Registered: August 2005
Member
Hello All,
I intend to use a materialized view , to develop a report.
I have set this view to do a complete refresh every nigth. My concern is, if for some reason the materialized view fails to refresh, the resulting report will not have the correct data.
How will I know if a materialized view refresh encountered an exception? And if so can I take any resulting action.

Thanks
PHK
Re: Metrialized View exceptions [message #268484 is a reply to message #268449] Tue, 18 September 2007 17:04 Go to previous messageGo to next message
andrew again
Messages: 2577
Registered: March 2000
Senior Member
the MV is scheduled using an entry in dba/all/user_jobs (at least up till 9i). It's possible to modify that job entry to log errors to a table or whatever. You need to re-modify the job each time you re-create the MV. It's important to note that DBMS_JOB scheduler will mark a job as permanently broken after a certain number of consecutive failures.

the DBA should be able to monitor the alert log for failed jobs.

You can also just call the job content directly from sqlplus via cron or whatever and email yourself on failure.


Re: Metrialized View exceptions [message #268750 is a reply to message #268484] Wed, 19 September 2007 10:33 Go to previous messageGo to next message
pkirangi
Messages: 74
Registered: August 2005
Member
Thanks Andrew,
Is the refresh always trigerred of by a DBMS_JOB?

Thanks
PHK
Re: Metrialized View exceptions [message #268765 is a reply to message #268750] Wed, 19 September 2007 11:19 Go to previous messageGo to next message
andrew again
Messages: 2577
Registered: March 2000
Senior Member
up till 9i is was yes. You'll need to confirm for 10g.
Re: Metrialized View exceptions [message #268803 is a reply to message #268765] Wed, 19 September 2007 15:02 Go to previous message
pkirangi
Messages: 74
Registered: August 2005
Member
Thanks Andrew.
Previous Topic: EXECUTE IMMEDIATE statements do not work
Next Topic: blob data migration
Goto Forum:
  


Current Time: Tue Dec 06 06:24:23 CST 2016

Total time taken to generate the page: 0.12259 seconds