Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
Anonymous
Not applicable

MQL TO SAL conversion

Hello,

 

Does anyone know of a DAX query which will calculate the conversion rate from MQL to SAL.

 

The below is an example of what I am trying to achieve

HarryB_0-1669510172618.png

 

 

Thanks,

 

Harrison

1 ACCEPTED SOLUTION
v-jianboli-msft
Community Support
Community Support

Hi @Anonymous ,

 

Please try:

First, create an index column:

vjianbolimsft_0-1669598778391.png

Output:

vjianbolimsft_1-1669598809263.png

Then apply the measure to a table visual:

 

Conversions = 
var _a = SUM('Table'[Value])
var _b = CALCULATE(SUM('Table'[Value]),FILTER(ALL('Table'),[Index]=MAX('Table'[Index])+1))
return DIVIDE(_b,_a)

Show items with no data:

vjianbolimsft_0-1669599261451.png

 

 

Final output:

vjianbolimsft_1-1669599283979.png

 

Best Regards,

Jianbo Li

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

2 REPLIES 2
v-jianboli-msft
Community Support
Community Support

Hi @Anonymous ,

 

Please try:

First, create an index column:

vjianbolimsft_0-1669598778391.png

Output:

vjianbolimsft_1-1669598809263.png

Then apply the measure to a table visual:

 

Conversions = 
var _a = SUM('Table'[Value])
var _b = CALCULATE(SUM('Table'[Value]),FILTER(ALL('Table'),[Index]=MAX('Table'[Index])+1))
return DIVIDE(_b,_a)

Show items with no data:

vjianbolimsft_0-1669599261451.png

 

 

Final output:

vjianbolimsft_1-1669599283979.png

 

Best Regards,

Jianbo Li

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Anonymous
Not applicable

Hi Jianbo Li,

 

Thank you!

 

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.