Use the result of two monitors to trigger an alert

I configured this query to trigger an alert when Monitor1 fails and Monitor2 success but it is NOT working because the first AND validation in the cases(WHERE()) sentence filter all the data related to the Monitor1 and the condition for the Monitor2 in the second AND conditional does not have data to compare.

FROM SyntheticCheck SELECT count(*) WHERE monitorName IN (‘Monitor1’,‘Monitor2’) FACET cases(WHERE ( X AND Y ) AND ( W AND Z ))

I there any way to trigger an alert based on the result of TWO different monitors?

FROM SyntheticCheck SELECT count(*) WHERE monitorName IN (‘Monitor1’,‘Monitor2’) FACET cases(WHERE (monitorName =‘Monitor1’ AND result !=‘SUCCESS’) AND (monitorName =‘Monitor2’ AND result =‘SUCCESS’))

Hi, @jorge.llanos: You may find this post helpful: https://discuss.newrelic.com/t/relic-solution-how-to-achieve-compound-alert-behavior/184653.

2 Likes