<?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 Calculation in previous row in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Calculation-in-previous-row/m-p/3038367#M104117</link>
    <description>&lt;P&gt;Hello Guys i have a problem,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;i get my data via directquery but i want to calculate everytime with previous rows. I want to get the seconds between every rows.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;Here is a example of it.&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;Thank you for your time&lt;/P&gt;</description>
    <pubDate>Mon, 23 Jan 2023 16:47:31 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2023-01-23T16:47:31Z</dc:date>
    <item>
      <title>Calculation in previous row</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Calculation-in-previous-row/m-p/3038367#M104117</link>
      <description>&lt;P&gt;Hello Guys i have a problem,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;i get my data via directquery but i want to calculate everytime with previous rows. I want to get the seconds between every rows.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;Here is a example of it.&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;Thank you for your time&lt;/P&gt;</description>
      <pubDate>Mon, 23 Jan 2023 16:47:31 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Calculation-in-previous-row/m-p/3038367#M104117</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2023-01-23T16:47:31Z</dc:date>
    </item>
    <item>
      <title>Re: Calculation in previous row</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Calculation-in-previous-row/m-p/3038588#M104129</link>
      <description>&lt;P&gt;Anonymous&lt;/LI-USER&gt; , You have to create a measure &lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;datediff(maxx(filter(all(Table), Table[Date] &amp;lt; max(Table[Date]) ), Table[Date]) , Max(Table[Date]) , Second)&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;or&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Sumx(Table, datediff(maxx(filter(all(Table), Table[Date] &amp;lt; max(Table[Date]) ), Table[Date]) , Max(Table[Date]) , Second) )&lt;/P&gt;</description>
      <pubDate>Mon, 23 Jan 2023 18:05:38 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Calculation-in-previous-row/m-p/3038588#M104129</guid>
      <dc:creator>amitchandak</dc:creator>
      <dc:date>2023-01-23T18:05:38Z</dc:date>
    </item>
    <item>
      <title>Re: Calculation in previous row</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Calculation-in-previous-row/m-p/3040059#M104224</link>
      <description>&lt;P&gt;I got this Error.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 24 Jan 2023 11:56:29 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Calculation-in-previous-row/m-p/3040059#M104224</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2023-01-24T11:56:29Z</dc:date>
    </item>
    <item>
      <title>Re: Calculation in previous row</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Calculation-in-previous-row/m-p/3040163#M104229</link>
      <description>&lt;P&gt;hi&amp;nbsp;Anonymous&lt;/LI-USER&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;try to plot the date1 column with a measure like:&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;MinuteDuration = 
VAR _date = MAX(TableName[Date1])
VAR _datepre=
MAXX(
    FILTER(ALL(TableName), TableName[Date1]&amp;lt;_date),
    TableName[Date1]
)
RETURN
DATEDIFF(_datepre, _date, MINUTE)+0&lt;/LI-CODE&gt;&lt;P&gt;it worked like this:&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Please ensure to feed the Date1 column directly, instead of the date hierarchy.&lt;/P&gt;</description>
      <pubDate>Tue, 24 Jan 2023 12:31:57 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Calculation-in-previous-row/m-p/3040163#M104229</guid>
      <dc:creator>FreemanZ</dc:creator>
      <dc:date>2023-01-24T12:31:57Z</dc:date>
    </item>
    <item>
      <title>Re: Calculation in previous row</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Calculation-in-previous-row/m-p/3042435#M104417</link>
      <description>&lt;P&gt;Do you know how i get this measure for only the rows that i got shown on my table and not for all of my over 1 000 000 rows?&lt;/P&gt;</description>
      <pubDate>Wed, 25 Jan 2023 11:22:44 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Calculation-in-previous-row/m-p/3042435#M104417</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2023-01-25T11:22:44Z</dc:date>
    </item>
  </channel>
</rss>

