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

Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!

Reply
neelofarshama
Post Partisan
Post Partisan

DAX for card with edit interactions column

Hi All,

I have a requirement where I have to display 3 cards Total Conversions, Site Conversions and Conv %(of Site).

The Conv%(of Site) is a DAX measure which is "TotalConversions/Sum(Site Conversions)".

The Site Conversion has been used Edit Interactions feature which will not be filtered with slicers Category and Mailing Name.

neelofarshama_1-1620071804382.png

The Problem arises when I am selecting the slicer Mailing Name or Category the value Site Conversions is not changing as the its using Edit interactions feature, the %Conv=1/12,210=0.008% but its showing up 0.4% as shown below.

neelofarshama_2-1620073488180.png

 

Please help me solve this Conv% DAX which should be calculated based on the Site conversions card display.

 

Thanks in Advance,

Neelofar Shama

1 ACCEPTED SOLUTION

Hi @neelofarshama ,

 

I have change the slicer for send date in SFMC_SENDS table to date in DAILY_SITE_CONVERSIONS, if you use send date it will be filter by the slicer mailing name even though you use the

ALL(SFMC_SENDS[Category],SFMC_SENDS[Mailing Name]), it will have no filter to your formula, but the slicer mailing name will filter the send date slicer, the send date slicer will have impact on the sum formula.

 

Then you can use the following measure:

site conversions = 
    CALCULATE (
        SUM ( DAILY_SITE_CONVERSIONS[CONVERSIONS] ),ALL(SFMC_SENDS[Category],SFMC_SENDS[Mailing Name]))

 

Please refer to the pbix file.

 

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

 

Best Regards,

Dedmon Dai

  

View solution in original post

9 REPLIES 9
v-deddai1-msft
Community Support
Community Support

Hi @neelofarshama ,

 

You don't need to edit Interactions between site conversions card and slicers. Just use the all function in your card measure:

 

Site conversions = SUMX(ALL(Table),Table[Site conversions])

 

Then you can use the  TotalConversions/Sum(Site Conversions) for  Conv%

 

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

 

Best Regards,

Dedmon Dai

Hi,

Thank you for the reply but I cannot use ALL() function as I have other columns in this table like "Property" and "Date" to filter the Site Conversion card as shown below. 

neelofarshama_0-1620295767032.png

All the slicers are in a different called Table3 but Site Conversion in in Table2.

amitchandak
Super User
Super User

@neelofarshama , try using all or remove filters

 

new %Con =

calculate([%Con], all(Table[Mailing Name]), all(Table[Category]))

 

or

 

new %Con =

calculate([%Con], removefilters(Table[Mailing Name],Table[Category]))

 

https://www.linkedin.com/pulse/five-recent-power-bi-functions-you-should-use-more-often-amit-chandak

Hi @amitchandak ,

 

I tried the DAX you have suggested is also not giving accurate results. Can you please suggest some alternative.

Hi @neelofarshama ,

 

Using something like below:

 

Conv%(of Site) = TotalConversions / CALCULATE(Sum(Site Conversions),REMOVRFILTERS(Table[Mailing Name],Table[Category]))

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

 

Best Regards,

Dedmon Dai

 

Hi  @v-deddai1-msft ,

I tried this but doesnt work for some reason I am not able to figure out.

Hi @neelofarshama ,

 

Would you please show me your sample pbix file? You must miss something to make the formula work.

 

Best Regards,

Dedmon Dai

 

Hi @neelofarshama ,

 

I have change the slicer for send date in SFMC_SENDS table to date in DAILY_SITE_CONVERSIONS, if you use send date it will be filter by the slicer mailing name even though you use the

ALL(SFMC_SENDS[Category],SFMC_SENDS[Mailing Name]), it will have no filter to your formula, but the slicer mailing name will filter the send date slicer, the send date slicer will have impact on the sum formula.

 

Then you can use the following measure:

site conversions = 
    CALCULATE (
        SUM ( DAILY_SITE_CONVERSIONS[CONVERSIONS] ),ALL(SFMC_SENDS[Category],SFMC_SENDS[Mailing Name]))

 

Please refer to the pbix file.

 

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

 

Best Regards,

Dedmon Dai

  

Helpful resources

Announcements
April AMA free

Microsoft Fabric AMA Livestream

Join us Tuesday, April 09, 9:00 – 10:00 AM PST for a live, expert-led Q&A session on all things Microsoft Fabric!

March Fabric Community Update

Fabric Community Update - March 2024

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