GoshPosh / grafana-meta-queries

Grafana plugin for calculating time period metrics like week over week, month over month and year over year etc.
Apache License 2.0
285 stars 71 forks source link

A+B without using a key #106

Open grambharos opened 3 years ago

grambharos commented 3 years ago

Hi Friend, Is it possible to have a sum of two queries without using a key value?

With Key value A: alias(query, 'cta') B: alias(query, 'ctb') C: A['cta']+B['ctb']

Without Key value is this possible or is there something similar ? A: query B: query C: A['*']+B['*']

Gauravshah commented 3 years ago

grafana doesn't have data like that. Can you post a screen shot of dashboard showing A & B (both panel config & data) that might help me better understand the request.

grambharos commented 3 years ago

Hi Gauravshah, An example like this, because I use regex

A: aliasSub(sumSeries(graphite.metrics.cloud1.*), '(.*)', '\1') B: aliasSub(sumSeries(graphite.metrics.cloud2.*), '(.*)', '\1') C: A['howtoregexkeyA']+B['howtoregexkeyB']

niltongouveajr commented 2 years ago

Hi @Gauravshah,

I have a similar question:

grafana

Can you help me?