This discussion has been locked. The information referenced herein may be inaccurate due to age, software updates, or external references.
You can no longer post new replies to this discussion. If you have a similar question you can start a new discussion in this forum.

Alert if audit log is missing for last 24 hours

Is there any possibility to achieve this. Not able to figure out what condition should I put under where clause so that I can receive an alert incase audit log is missing for say last 24 hours or 12 hour depending upon the requirement

Parents
  • Have been working on this part.

    I have set the trigger condition as below & modified the sql condition for email as below so that I'll receive alert if audit is not present for last 30 min's (including evaluation time as 15 min)

    SELECT
    case when count (timeloggedutc)>0
    then 'Audit is present for last 30 minutes'
    else 'Audit is not present for last 30 minutes'
    end
    FROM AuditingEvents
    where timeloggedutc>(DATEADD(minute, -30, (select DATEADD(hour, -6, getutcdate()))))

Reply
  • Have been working on this part.

    I have set the trigger condition as below & modified the sql condition for email as below so that I'll receive alert if audit is not present for last 30 min's (including evaluation time as 15 min)

    SELECT
    case when count (timeloggedutc)>0
    then 'Audit is present for last 30 minutes'
    else 'Audit is not present for last 30 minutes'
    end
    FROM AuditingEvents
    where timeloggedutc>(DATEADD(minute, -30, (select DATEADD(hour, -6, getutcdate()))))

Children
No Data