Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

summarise alias #833

Merged
merged 2 commits into from
May 20, 2024
Merged

summarise alias #833

merged 2 commits into from
May 20, 2024

Conversation

yesoreyeram
Copy link
Collaborator

Description

This PR adds the "summarize alias" option when used with backend parser.

Problem statement

When you have multiple queries with summarize option, all the values will be shown as summary. This makes hard to differentiate the values and also hard to operate when used with grafana merge transformation.

Example: Without alias and merge transformation

Here I am using two different queries. One for returning mean age and another one for mean salary

image image image

then I am using merge transformation to merge these two results.

image

but this is not what I want also Join by field transformation also doesn't give me the result I want.

image

Solution

The solution here is to use summarize alias in the queries to differentiate the metrics.

image image

then just using the merge transformation should work

image

@yesoreyeram yesoreyeram requested a review from a team as a code owner May 3, 2024 11:30
Copy link
Contributor

@gabor gabor left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 👍

@yesoreyeram yesoreyeram merged commit 23b6ed4 into main May 20, 2024
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants