Open dgieselaar opened 1 week ago
Pinging @elastic/es-analytical-engine (Team:Analytics)
I wonder if IF_EXISTS
could be a function that's a noop if the field exists and null
if it doesn't.
EQL has "optional fields": https://www.elastic.co/guide/en/elasticsearch/reference/current/eql-syntax.html#eql-syntax-optional-fields
@astefan IMHO a syntax like that (I assume this conflicts with params) would be ideal (over a function)
Description
As an engineer, I sometimes have to query a set of indices, where I'm not sure if a field exists in those indices, but I also don't care. E.g., I might want to group by service.name and service.environment in
logs-*
, but the user might only have service.name. I want to signal to the_query
endpoint that it's OK ifservice.environment
does not exist. Currently this fails:per @not-napoleon's suggestion, we could do something like this:
I would like it to work for
STATS
but also things likeWHERE
,EVAL
, etc.