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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
HarryB
Resolver I
Resolver I

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 @HarryB ,

 

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 @HarryB ,

 

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.

Hi Jianbo Li,

 

Thank you!

 

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.