<?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: Row-wise Sum within a date range in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Row-wise-Sum-within-a-date-range/m-p/1820263#M38607</link>
    <description>&lt;P&gt;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="248281" data-lia-user-login="CliffordAP" class="lia-mention lia-mention-user"&gt;CliffordAP&lt;/a&gt; , Not very clear, Try a measure like&lt;/P&gt;
&lt;P&gt;calculate(sum(Table[Amount]), filter(Table, Table[Date] &amp;gt;=today() -7 &amp;amp;&amp;amp; Table[Date] &amp;lt;=today()))&lt;/P&gt;</description>
    <pubDate>Mon, 03 May 2021 16:26:24 GMT</pubDate>
    <dc:creator>amitchandak</dc:creator>
    <dc:date>2021-05-03T16:26:24Z</dc:date>
    <item>
      <title>Row-wise Sum within a date range</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Row-wise-Sum-within-a-date-range/m-p/1820100#M38603</link>
      <description>&lt;P&gt;Hello all,&lt;/P&gt;&lt;P&gt;I am trying to do an aggregation of transactions that happen between people and between a date range of 7 days.&lt;/P&gt;&lt;P&gt;I want this calculation to be done row-wise, meaning that every transaction will show a sum of transactions within the last 7 days.&lt;/P&gt;&lt;P&gt;Here is what the data looks like, and the final column is the output I am looking for.&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;See how for every record, the calculation sums all transactions within the last 7 days for that person.&lt;/P&gt;&lt;P&gt;Does anyone have any ideas? I have tried a few CALCULATE functions, and I don't see any posts similar to this. I'm sure there must be a way to do this.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you&lt;/P&gt;</description>
      <pubDate>Mon, 03 May 2021 15:11:38 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Row-wise-Sum-within-a-date-range/m-p/1820100#M38603</guid>
      <dc:creator>CliffordAP</dc:creator>
      <dc:date>2021-05-03T15:11:38Z</dc:date>
    </item>
    <item>
      <title>Re: Row-wise Sum within a date range</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Row-wise-Sum-within-a-date-range/m-p/1820263#M38607</link>
      <description>&lt;P&gt;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="248281" data-lia-user-login="CliffordAP" class="lia-mention lia-mention-user"&gt;CliffordAP&lt;/a&gt; , Not very clear, Try a measure like&lt;/P&gt;
&lt;P&gt;calculate(sum(Table[Amount]), filter(Table, Table[Date] &amp;gt;=today() -7 &amp;amp;&amp;amp; Table[Date] &amp;lt;=today()))&lt;/P&gt;</description>
      <pubDate>Mon, 03 May 2021 16:26:24 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Row-wise-Sum-within-a-date-range/m-p/1820263#M38607</guid>
      <dc:creator>amitchandak</dc:creator>
      <dc:date>2021-05-03T16:26:24Z</dc:date>
    </item>
    <item>
      <title>Re: Row-wise Sum within a date range</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Row-wise-Sum-within-a-date-range/m-p/1820277#M38610</link>
      <description>&lt;P&gt;Ah, I do need to clarify.&lt;BR /&gt;I don't want the previous 7 days from today, I need the previous 7 days from the recorded date.&lt;BR /&gt;So for each record, the calculation will look into the previous 7 days from the recorded date and sum the transactions within those 7 days.&lt;BR /&gt;I'm getting something close with;&lt;BR /&gt;&lt;SPAN&gt;CALCULATE&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;SUM&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;'table'[amount]&lt;/SPAN&gt;&lt;SPAN&gt;)&lt;/SPAN&gt;&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;,&lt;SPAN&gt;ALLSELECTED&lt;/SPAN&gt;&lt;SPAN&gt;()&lt;/SPAN&gt;&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;,&lt;SPAN&gt;DATESBETWEEN&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;'table'[Date]&lt;/SPAN&gt;,&lt;SPAN&gt;'table'[Date]&lt;/SPAN&gt;,&lt;SPAN&gt;DATEADD&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;'table'[Date]&lt;/SPAN&gt;,-&lt;SPAN&gt;7&lt;/SPAN&gt;,&lt;SPAN&gt;DAY&lt;/SPAN&gt;&lt;SPAN&gt;)))&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&lt;BR /&gt;&lt;/SPAN&gt;But it's not perfect..&lt;BR /&gt;&lt;BR /&gt;Thank you for your response.&lt;/P&gt;</description>
      <pubDate>Mon, 03 May 2021 16:33:47 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Row-wise-Sum-within-a-date-range/m-p/1820277#M38610</guid>
      <dc:creator>CliffordAP</dc:creator>
      <dc:date>2021-05-03T16:33:47Z</dc:date>
    </item>
  </channel>
</rss>

