If statement in timelion

Is it possible to exclude a document based on a value in a field?
In my case, I want to count the ammount of errors, but only if the field 'status' is not set to 3 (Range from 1 to 6).
I have found tahe blog about if's in Timelion https://www.elastic.co/blog/timeseries-if-then-else-with-timelion?baymax=rtp&storm=recommendation&elektra=blog&iesrc=rcmd&astid=8e0aef24-80c1-423b-87a9-f591a5514e99&at=16&rcmd_source=WIDGET&req_id=2cda7599-aa3f-4e7f-9541-627416df87e9. Unfortunately it didn't helped me.

Hi there,

You need to add a filter to the query Timelion uses to retrieve documents for visualizing. In your use case, your filter will exclude any document which has a value of 3 for its "status" field. You can do this like so:


See this related thread for more info.

Hope this helps,

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.