Thanks for the reply!
I solved now, for the future readers the correct way is this one:
max by (
_id, account, ebs_account, email_domain,
external_organization,
managed, support, risk
) (
subscription_labels{email_domain!~"google.com"} } + on
(_id) group_left(_ignore)
(0 * topk by (_id) (1,
cluster_version{{version=~"4.[2-9].*",type="current"}}))
*or on (_id) subscription_labels{email_domain!~"google.com
<http://google.com>"} }*
)
On Wednesday, September 23, 2020 at 7:05:13 PM UTC+2 [email protected]
wrote:
> https://www.robustperception.io/left-joins-in-promql
>
> Build the query up in steps. I am guessing you want the "or on" condition
> inside the max by, not outside it.
>
--
You received this message because you are subscribed to the Google Groups
"Prometheus Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/prometheus-users/5f3ae0a5-6cf9-4943-a9e7-6f598c760649n%40googlegroups.com.