<?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 Re: Dax measure to get previous 7days and next 7days of selected date in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Dax-measure-to-get-previous-7days-and-next-7days-of-selected/m-p/2750239#M84827</link>
    <description>&lt;P&gt;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="435159" data-lia-user-login="prv_1401" class="lia-mention lia-mention-user"&gt;prv_1401&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Yes, [Total Sales] is a measure.&amp;nbsp; You can replace it with any measure and the pattern should work, so one that returns a %age will be fine.&lt;/P&gt;</description>
    <pubDate>Tue, 06 Sep 2022 12:20:18 GMT</pubDate>
    <dc:creator>PaulOlding</dc:creator>
    <dc:date>2022-09-06T12:20:18Z</dc:date>
    <item>
      <title>Dax measure to get previous 7days and next 7days of selected date</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Dax-measure-to-get-previous-7days-and-next-7days-of-selected/m-p/2748560#M84730</link>
      <description>&lt;P&gt;Hey guys !&lt;/P&gt;&lt;P&gt;&amp;nbsp;I am very new to PowerBI. Could you suggest me the Dax functions or the syntax with any examples to solve this issue .&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have to show a line chart visual which shows the previous 7days value and after 7days value of a selected date . So if I select a particular date the measure should filter the visual according to it and show according to the requirement .&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Appreciate any help. Thank you &lt;span class="lia-unicode-emoji" title=":heart_suit:"&gt;♥️&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 05 Sep 2022 19:06:46 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Dax-measure-to-get-previous-7days-and-next-7days-of-selected/m-p/2748560#M84730</guid>
      <dc:creator>prv_1401</dc:creator>
      <dc:date>2022-09-05T19:06:46Z</dc:date>
    </item>
    <item>
      <title>Re: Dax measure to get previous 7days and next 7days of selected date</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Dax-measure-to-get-previous-7days-and-next-7days-of-selected/m-p/2748657#M84738</link>
      <description>&lt;P&gt;If you're very new to Power BI, I would then kindly suggest you should learn a bit about the philosophy of PBI because what you want to do is not the easiest thing under the sun. Here's an example of what you'd need to , more or less, implement:&amp;nbsp;&lt;A href="https://www.youtube.com/watch?v=d8Rm7dwM6gc" target="_blank"&gt;Show last 6 months based on user single slicer selection (youtube.com)&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 05 Sep 2022 19:56:04 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Dax-measure-to-get-previous-7days-and-next-7days-of-selected/m-p/2748657#M84738</guid>
      <dc:creator>daXtreme</dc:creator>
      <dc:date>2022-09-05T19:56:04Z</dc:date>
    </item>
    <item>
      <title>Re: Dax measure to get previous 7days and next 7days of selected date</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Dax-measure-to-get-previous-7days-and-next-7days-of-selected/m-p/2748696#M84741</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="435159" data-lia-user-login="prv_1401" class="lia-mention lia-mention-user"&gt;prv_1401&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;This solution uses a disconnected date table called 'Date Selector' (meaning it's a date table without any relationship to another table).&amp;nbsp; The slicer should use this table.&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;7and7 = 
VAR _SelectedDate = SELECTEDVALUE('Date Selector'[Date])
VAR _Dates = DATESBETWEEN('Date'[Date], _SelectedDate - 7, _SelectedDate + 7)
VAR _Result =
CALCULATE(
    [Total Sales],
    KEEPFILTERS(_Dates)
    )
RETURN
    _Result&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;The line chart uses the Date column from the Date table.&lt;/P&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 05 Sep 2022 20:36:18 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Dax-measure-to-get-previous-7days-and-next-7days-of-selected/m-p/2748696#M84741</guid>
      <dc:creator>PaulOlding</dc:creator>
      <dc:date>2022-09-05T20:36:18Z</dc:date>
    </item>
    <item>
      <title>Re: Dax measure to get previous 7days and next 7days of selected date</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Dax-measure-to-get-previous-7days-and-next-7days-of-selected/m-p/2749265#M84778</link>
      <description>&lt;P&gt;Hi ..Thank you for replying&amp;nbsp;&lt;BR /&gt;what if the sales value in the table is percentage % ??&lt;BR /&gt;So for instance sales % for eachdate is given. You have mentioned there in dax [total sales] Is that a measure you created? .&lt;BR /&gt;In case of % how should I deal with it ?&lt;BR /&gt;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="150936" data-lia-user-login="PaulOlding" class="lia-mention lia-mention-user"&gt;PaulOlding&lt;/a&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 06 Sep 2022 06:07:27 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Dax-measure-to-get-previous-7days-and-next-7days-of-selected/m-p/2749265#M84778</guid>
      <dc:creator>prv_1401</dc:creator>
      <dc:date>2022-09-06T06:07:27Z</dc:date>
    </item>
    <item>
      <title>Re: Dax measure to get previous 7days and next 7days of selected date</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Dax-measure-to-get-previous-7days-and-next-7days-of-selected/m-p/2750239#M84827</link>
      <description>&lt;P&gt;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="435159" data-lia-user-login="prv_1401" class="lia-mention lia-mention-user"&gt;prv_1401&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Yes, [Total Sales] is a measure.&amp;nbsp; You can replace it with any measure and the pattern should work, so one that returns a %age will be fine.&lt;/P&gt;</description>
      <pubDate>Tue, 06 Sep 2022 12:20:18 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Dax-measure-to-get-previous-7days-and-next-7days-of-selected/m-p/2750239#M84827</guid>
      <dc:creator>PaulOlding</dc:creator>
      <dc:date>2022-09-06T12:20:18Z</dc:date>
    </item>
  </channel>
</rss>

