cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
kevininnovafeed
Regular Visitor

Automatically create measures from a result of SQL Query

Hello all,

I'm trying to give some independance to users by giving them the possibility to create their own power BI report based on a SQL query that they can customize.

 

Basically, the result of the query is :

- one column of "datetime" with datetime value

- n columns of "sensors" (flowmeters, thermometer ...) with numeric values 

 

=> sensors columns may vary, depending on the SQL query, from 2 to >100 columns. 

 

And the visuals on Power BI should be quite simple : bar/line chart with :

x = datetime

y = measure based on 1 sensor, with the possibility to show several measures   

 

=> I want to avoid creating measures automatically : because of the numbers of measures possibles (>100), and also because the list of sensors will always vary.
=> I'm trying to generate automatically measures for each sensor (so for each column) by selecting it through a slicer. Do you think it is possible?

 

 

 

Many thanks for your help, i didn't find any solutions in the forum and on the web (nor chat gpt ;))

 

datesensor 1sensor 2sensor 3
01/01/2023183
02/01/20237110
03/01/20232910
04/01/2023295
05/01/20239510
06/01/2023315
07/01/2023796
08/01/2023982
09/01/2023984
10/01/2023545
11/01/20231029
12/01/2023721

 

 

0 REPLIES 0

Helpful resources

Announcements
May 2023 update

Power BI May 2023 Update

Find out more about the May 2023 update.

Submit your Data Story

Data Stories Gallery

Share your Data Story with the Community in the Data Stories Gallery.

Top Solution Authors