Combine 2 data sources for labelling

*** What Grafana version and what operating system are you using?**
Grafana v10.1.0 (ff85ec33c5) with docker on Amazon EC2

*** What are you trying to achieve?**
Display time series data from influx and replace labels to values stored in MySQL database. Graph legend should display the matching values from MySQL.Please see attached picture for visualization

*** How are you trying to achieve it?**

I’m using mixed data sources: influx for time series data (labelled with MAC address) and a second source from mySQL that stores friendly name of the device behind a MAC address.

I want to combine the data in the transformation section with no luck so far.

*** What happened?**

Can’t achive the desired results. Not sure if the selected approach is correct.

*** Can you copy/paste the configuration(s) that you are having problems with?**

Influx query:

from(bucket: "sensor_data")
  |> range(start: v.timeRangeStart, stop:v.timeRangeStop)
  |> filter(fn: (r) =>
    r._measurement == "sensor_data" and
    r._field == "power"

MySQL Query: