Distinguish errors in query

Our engineering team advised us that certain errors can be ignored from the error count here. Can we modify this query to filter out specific errors from the count?

SELECT count(apm.service.error.count) / count(apm.service.transaction.duration) as ‘Web errors’ FROM Metric WHERE (entity.guid = ‘MjU1MjAyNnxBUE18QVBQTElDQVRJT058NzY0MzQxNDQ5’) AND (transactionType = ‘Web’) SINCE 1800 seconds AGO TIMESERIES

Hi, @infrastructure44: I recommend querying TransactionError events rather than Metric:

SELECT (count(transactionName) / count(name)) * 100 AS 'Error rate' 
FROM TransactionError, Transaction 
WHERE appName = 'Your Application'
  AND error.class NOT IN ('errors to ignore')

For certain agents, you may also specify that some errors are expected, then filter them this way:

WHERE error.expected IS false

That worked, thanks!