Grafana can't makes alert by expression with es datasource

We use grafana for alert configuration, which is based on conversion rate.
The data source of grafana is ES (Elasticsearch).

  1. First set up 2 queries in query,
    buyCnt: Number of page button clicks.
    pageCnt: is the number of page impressions
    Conversion via Expression: rate = $buyCnt / $pageCnt.

  2. In the alert, set the alarm according to the rate, and prompt an error: The datasource does not support alerting queries

@huanting welcome to the :grafana: community!

Which version of grafana are you using? Elasticsearch has had alerting support since 5.2. Do you only see this issue with the expression in the alert?

It looks like you’re using the legacy grafana alerts - I tried this in grafana 8.5 with new alerts (where the expression is created in the alert instead of the dashboard and it seems like it should work: