<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Removing Filter Context in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Removing-Filter-Context/m-p/4037451#M160043</link>
    <description>&lt;P&gt;Hi,&lt;BR /&gt;&lt;BR /&gt;I really need help with, what I think is a DAX issue.&lt;BR /&gt;&lt;BR /&gt;I have on my report page, two tables. Each table displays my companies top 25 energy-using facilities and their respective correlation cofficients x=date and y= SEC (kWh/ML) - SEC is a measure.&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The page has one filter, which is Year/Month, which is a calculated column - FORMAT('Calendar'[Date], "YYYY-MM")&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;The first table dynamically displays the correlation by the chosen Year/Month (so, taking into account only the SEC values for that given Year/Month) and the second table calculates the &lt;SPAN&gt;correlation by the chosen Year/Month, but also takes into account the previous two months. This is essentially a rolling 3-months. I have the correlation measure providing the correct output for the second table, but where I become unstuck, is the custom tooltip for the second table.&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;I have a custom tooltip page simply displaying SEC(kWh/ML) in the y-axis and the Date in the x-axis. This isn't a problem for the first table as it only shows the correlation by month, but for the second table I need the custom tooltip line chart to show 3-months (current Year/Month selection and two months prior).&lt;BR /&gt;&lt;BR /&gt;I am trying to drive both tables by the same slicer (Year/Month), despite having two different granularities, which I think is causing the issue. The slicer is imposing the 1-month view on the 3-monthly set up of the second table. I have tried all sorts of combinations to remove the filter context, so the custom tooltip line chart will display the current Year/Month and the two previous months, but with no success. I'm hoping some clever person can help resolve this.&lt;BR /&gt;&lt;BR /&gt;Many thanks&amp;nbsp;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;</description>
    <pubDate>Thu, 11 Jul 2024 16:27:35 GMT</pubDate>
    <dc:creator>Arclite</dc:creator>
    <dc:date>2024-07-11T16:27:35Z</dc:date>
    <item>
      <title>Removing Filter Context</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Removing-Filter-Context/m-p/4037451#M160043</link>
      <description>&lt;P&gt;Hi,&lt;BR /&gt;&lt;BR /&gt;I really need help with, what I think is a DAX issue.&lt;BR /&gt;&lt;BR /&gt;I have on my report page, two tables. Each table displays my companies top 25 energy-using facilities and their respective correlation cofficients x=date and y= SEC (kWh/ML) - SEC is a measure.&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The page has one filter, which is Year/Month, which is a calculated column - FORMAT('Calendar'[Date], "YYYY-MM")&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;The first table dynamically displays the correlation by the chosen Year/Month (so, taking into account only the SEC values for that given Year/Month) and the second table calculates the &lt;SPAN&gt;correlation by the chosen Year/Month, but also takes into account the previous two months. This is essentially a rolling 3-months. I have the correlation measure providing the correct output for the second table, but where I become unstuck, is the custom tooltip for the second table.&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;I have a custom tooltip page simply displaying SEC(kWh/ML) in the y-axis and the Date in the x-axis. This isn't a problem for the first table as it only shows the correlation by month, but for the second table I need the custom tooltip line chart to show 3-months (current Year/Month selection and two months prior).&lt;BR /&gt;&lt;BR /&gt;I am trying to drive both tables by the same slicer (Year/Month), despite having two different granularities, which I think is causing the issue. The slicer is imposing the 1-month view on the 3-monthly set up of the second table. I have tried all sorts of combinations to remove the filter context, so the custom tooltip line chart will display the current Year/Month and the two previous months, but with no success. I'm hoping some clever person can help resolve this.&lt;BR /&gt;&lt;BR /&gt;Many thanks&amp;nbsp;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 11 Jul 2024 16:27:35 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Removing-Filter-Context/m-p/4037451#M160043</guid>
      <dc:creator>Arclite</dc:creator>
      <dc:date>2024-07-11T16:27:35Z</dc:date>
    </item>
    <item>
      <title>Re: Removing Filter Context</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Removing-Filter-Context/m-p/4037547#M160054</link>
      <description>&lt;P&gt;Hey, could you please, send the graph (you copy paste in two seconds your screen here) and your Dax measure? I could&amp;nbsp; say that it could&amp;nbsp; be usefull to use removefillter() in your calculate() but if I don't see your measure this doesn't help.&lt;/P&gt;</description>
      <pubDate>Thu, 11 Jul 2024 16:06:20 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Removing-Filter-Context/m-p/4037547#M160054</guid>
      <dc:creator>GuillaumePower</dc:creator>
      <dc:date>2024-07-11T16:06:20Z</dc:date>
    </item>
    <item>
      <title>Re: Removing Filter Context</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Removing-Filter-Context/m-p/4045943#M160470</link>
      <description>&lt;P&gt;Hi,&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;Sorry for delayed reply. Here is the measure, I'm using this measure in the y-axis of the custom tooltip and date from my calendar table in the x-axis&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;SEC 3-Month Rolling =&lt;BR /&gt;VAR SelectedMonthYear = SELECTEDVALUE('Calendar'[MonthYear])&lt;BR /&gt;VAR SelectedYear = VALUE(LEFT(SelectedMonthYear, 4))&lt;BR /&gt;VAR SelectedMonth = VALUE(RIGHT(SelectedMonthYear, 2))&lt;BR /&gt;VAR CurrentDate = DATE(SelectedYear, SelectedMonth, 1)&lt;/P&gt;&lt;P&gt;-- Calculate start and end dates for the 3-month period&lt;BR /&gt;VAR EndDate = EOMONTH(CurrentDate, 0)&lt;BR /&gt;VAR StartDate = EOMONTH(CurrentDate, -2) + 1&lt;/P&gt;&lt;P&gt;-- Calculate SEC (kWh/ML) for the date range&lt;BR /&gt;RETURN&lt;BR /&gt;CALCULATE(&lt;BR /&gt;[SEC (kWh/ML)], -- Use the existing measure&lt;BR /&gt;REMOVEFILTERS('Calendar'[MonthYear]), -- Remove the MonthYear filter context&lt;BR /&gt;DATESBETWEEN(&lt;BR /&gt;'Calendar'[Date],&lt;BR /&gt;StartDate,&lt;BR /&gt;EndDate&lt;BR /&gt;)&lt;BR /&gt;)&lt;BR /&gt;&lt;BR /&gt;What you can see in the image (redacted), is a table with 25 facility names and their respective correlation coefficients based on Year-Month slicer (visible). The custom tooltip works perfectly in the context of the 1-month view, as its being governed by the YearMonth slicer. However, I have a toggle (also visible) where I switch a second table that shows the same 25 facilities but, this time with correlation coefficients for the 3-months (the chosen YearMonth and 2 months prior). Despite, what I have tried, I can't seem to show 3-months of data in the custom tooltip. You can clearly see the line is flat, as the measure isn't working. In a previous iteration of the report, I had 2 separate slicers, each controlling their respective table, but I have been asked by a stakeholder specifically to have only 1 slicer on the page. Any help would be much appreciated. Thanks&lt;img /&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 17 Jul 2024 10:35:15 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Removing-Filter-Context/m-p/4045943#M160470</guid>
      <dc:creator>Arclite</dc:creator>
      <dc:date>2024-07-17T10:35:15Z</dc:date>
    </item>
  </channel>
</rss>

