2 Replies Latest reply: Oct 27, 2011 12:19 AM by PramodHattarge RSS

    Issue with Oracle Alerts after a recent chagne

    PramodHattarge
      Hi,

      We use Oracle Alerts to send remainder emails regarding pending notifications. And we have configured these alerts to be run on specific dates of a month like 12th and 15th. For fixing any issues, we do the changes on our dev/test instance and extract them to an LDT and get them tested on QA instance and then move it to Production instance.

      We have made a recent change to couple of the alerts which were supposed to be run on every 12th and 15th day of a calendar month, but after the changes they are run daily.

      Following are the changes:
      LDT extract before change:

      BEGIN ALR_ALERTS "XBOL" "BAC OTL India Payroll Reminders to Managers on 12"
      OWNER = "05132"
      ALERT_CONDITION_TYPE = "P"
      ENABLED_FLAG = "Y"
      START_DATE_ACTIVE = "2009/08/13 00:00:00"
      DESCRIPTION = "Payroll Reminders to Managers on 12th of month"
      FREQUENCY_TYPE = "M"
      MONTHLY_CHECK_DAY_NUM = "12"
      DATE_LAST_CHECKED = "2010/02/22 05:12:08"
      MAINTAIN_HISTORY_DAYS = "5"
      CHECK_START_TIME = "48600"
      SQL_STATEMENT_TEXT =
      "SELECT\n\

      ...

      "

      LDT extract after change:

      BEGIN ALR_ALERTS "XBOL" "BAC OTL India Payroll Reminders to Managers on 12"
      OWNER = "021Y3"
      ALERT_CONDITION_TYPE = "P"
      ENABLED_FLAG = "Y"
      START_DATE_ACTIVE = "2009/08/13 00:00:00"
      DESCRIPTION = "Payroll Reminders to Managers on 12th of month"
      FREQUENCY_TYPE = "M"
      MONTHLY_CHECK_DAY_NUM = "12"
      DATE_LAST_CHECKED = "2010/02/22 05:12:08"
      MAINTAIN_HISTORY_DAYS = "30"
      CHECK_START_TIME = "0"
      SQL_STATEMENT_TEXT =
      "select\n\

      ...

      "

      From the above, you can see nothing apart from MAINTAIN_HISTORY_DAYS & CHECK_START_TIME and the SQL query has been changed. Still the frequence type is M(monthly) and day to run is 12th. But still its being run daily.

      Can you please let me know why changing history days and check start time is impacting the alert behavior over here. Is this expected behavior ?
      Is it due to the date_last_checked being in 2010 ? If so, why the same behavior wasn't observed before change/fix ?

      Regards,
      Pramod.
        • 1. Re: Issue with Oracle Alerts after a recent chagne
          Gaurav Bhardwaj
          Hello

          You can review Periodic Alert does not Run at Scheduled Time, Runs when Periodic Alert Scheduler Runs [ID 1016672.102] and Periodic Alert Scheduled for On Day of the Month, Runs on Day Enabled [ID 427965.1] , not sure if it will help you but don't think issue in reviewing it.

          Thanks
          Gaurav
          • 2. Re: Issue with Oracle Alerts after a recent chagne
            PramodHattarge
            Thanks for your response Gaurav. Reviewed the pointed out metalink note id's and they were very helpful.

            The NEXT_SCHEDULED_CHECK in alr_periodic_alerts_view is set to 'T' for these two alerts which means it will be picked up by the next Periodic Scheduler run and hence it picked up. That clarifies the issue.

            But this behavior was experienced only after the recent change, and with the past changes to these alerts, it used to get fired only on the scheduled date(like 12th in this case) and even at that times the NEXT_SCHEDULED_CHECK was set to 'T'.

            The only extra modification this time was CHECK_START_TIME which was changed from 48600 to 0.
            I was able to investigate further on this and when I set this back to 48600 and take date_last_checked back in time for this alert, it was not getting fired/run in the next time. Its running on the scheduled date only.

            Appreciate any explanation on this ?