<?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: DATEDIFF as DAX Measure in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DATEDIFF-as-DAX-Measure/m-p/1238385#M20262</link>
    <description>&lt;P&gt;Anonymous&lt;/LI-USER&gt; ,&lt;/P&gt;
&lt;P&gt;[Date1] -[Date2] will give in that format.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If you get in in second, minute or hour refer this for the duration of your choice&lt;/P&gt;
&lt;P&gt;&lt;A href="https://radacad.com/calculate-duration-in-days-hours-minutes-and-seconds-dynamically-in-power-bi-using-dax" target="_blank"&gt;https://radacad.com/calculate-duration-in-days-hours-minutes-and-seconds-dynamically-in-power-bi-using-dax&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&lt;A href="https://www.pbiusergroup.com/communities/community-home/digestviewer/viewthread?GroupId=547&amp;amp;MessageKey=814a2cb4-3cca-4cd1-a620-c467adeaaaf6&amp;amp;CommunityKey=b35c8468-2fd8-4e1a-8429-322c39fe7110&amp;amp;tab=digestviewer" target="_blank"&gt;https://www.pbiusergroup.com/communities/community-home/digestviewer/viewthread?GroupId=547&amp;amp;MessageKey=814a2cb4-3cca-4cd1-a620-c467adeaaaf6&amp;amp;CommunityKey=b35c8468-2fd8-4e1a-8429-322c39fe7110&amp;amp;tab=digestviewer&lt;/A&gt;&lt;/P&gt;</description>
    <pubDate>Tue, 21 Jul 2020 12:30:42 GMT</pubDate>
    <dc:creator>amitchandak</dc:creator>
    <dc:date>2020-07-21T12:30:42Z</dc:date>
    <item>
      <title>DATEDIFF as DAX Measure</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DATEDIFF-as-DAX-Measure/m-p/1238352#M20260</link>
      <description>&lt;P&gt;Hello all,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am trying to create a measure that calculates the difference between 2 time columns (hh:mm:ss format) and gives a result as a decimal. DATEDIFF works as a calculated column, but I cannot figure out how to translate to a DAX Measure. My report is saying there is too much space being taken up, so I want to change these columns to measures.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Please help!&lt;/P&gt;</description>
      <pubDate>Tue, 21 Jul 2020 12:21:23 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DATEDIFF-as-DAX-Measure/m-p/1238352#M20260</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2020-07-21T12:21:23Z</dc:date>
    </item>
    <item>
      <title>Re: DATEDIFF as DAX Measure</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DATEDIFF-as-DAX-Measure/m-p/1238385#M20262</link>
      <description>&lt;P&gt;Anonymous&lt;/LI-USER&gt; ,&lt;/P&gt;
&lt;P&gt;[Date1] -[Date2] will give in that format.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If you get in in second, minute or hour refer this for the duration of your choice&lt;/P&gt;
&lt;P&gt;&lt;A href="https://radacad.com/calculate-duration-in-days-hours-minutes-and-seconds-dynamically-in-power-bi-using-dax" target="_blank"&gt;https://radacad.com/calculate-duration-in-days-hours-minutes-and-seconds-dynamically-in-power-bi-using-dax&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&lt;A href="https://www.pbiusergroup.com/communities/community-home/digestviewer/viewthread?GroupId=547&amp;amp;MessageKey=814a2cb4-3cca-4cd1-a620-c467adeaaaf6&amp;amp;CommunityKey=b35c8468-2fd8-4e1a-8429-322c39fe7110&amp;amp;tab=digestviewer" target="_blank"&gt;https://www.pbiusergroup.com/communities/community-home/digestviewer/viewthread?GroupId=547&amp;amp;MessageKey=814a2cb4-3cca-4cd1-a620-c467adeaaaf6&amp;amp;CommunityKey=b35c8468-2fd8-4e1a-8429-322c39fe7110&amp;amp;tab=digestviewer&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 21 Jul 2020 12:30:42 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DATEDIFF-as-DAX-Measure/m-p/1238385#M20262</guid>
      <dc:creator>amitchandak</dc:creator>
      <dc:date>2020-07-21T12:30:42Z</dc:date>
    </item>
    <item>
      <title>Re: DATEDIFF as DAX Measure</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DATEDIFF-as-DAX-Measure/m-p/1238405#M20264</link>
      <description>&lt;P&gt;The DAX measure does not give me the option to call the entire column, so I cannot use [Date 1] - [Date 2]. In this case I would need a function that allows me to subtract 2 columns that are in the date format.&lt;/P&gt;</description>
      <pubDate>Tue, 21 Jul 2020 12:40:56 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DATEDIFF-as-DAX-Measure/m-p/1238405#M20264</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2020-07-21T12:40:56Z</dc:date>
    </item>
    <item>
      <title>Re: DATEDIFF as DAX Measure</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DATEDIFF-as-DAX-Measure/m-p/1238421#M20265</link>
      <description>&lt;P&gt;Anonymous&lt;/LI-USER&gt;&amp;nbsp;, in Measure you need to&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;measure = max([Date1]) -min([Date2])&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Take care row context while using. refer this blog how summarize and valuea has been used&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&lt;A href="https://community.powerbi.com/t5/Community-Blog/Decoding-Direct-Query-in-Power-BI-Part-2-Date-Difference-Across/ba-p/934397#M451&amp;nbsp;" target="_blank"&gt;https://community.powerbi.com/t5/Community-Blog/Decoding-Direct-Query-in-Power-BI-Part-2-Date-Difference-Across/ba-p/934397#M451&amp;nbsp;&lt;/A&gt;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 21 Jul 2020 12:46:31 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DATEDIFF-as-DAX-Measure/m-p/1238421#M20265</guid>
      <dc:creator>amitchandak</dc:creator>
      <dc:date>2020-07-21T12:46:31Z</dc:date>
    </item>
    <item>
      <title>Re: DATEDIFF as DAX Measure</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DATEDIFF-as-DAX-Measure/m-p/1238773#M20280</link>
      <description>&lt;P&gt;I tried that measure and when I put it in a table it only gives one value. I am trying to replicate the following column as a DAX measure:&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;This was calculated using the following calculation:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;Start Time Variance = &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;DATEDIFF('bv AFKO: Order Header Data PP Orders'[GSUZS_SIMP_TM: (GC) Scheduled Start (Time)] , 'bv AFKO: Order Header Data PP Orders'[GSUZI_SIMP_TM: (GC) Actual start time] , MINUTE) / 60&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;The columns in the calculation are the following:&lt;/DIV&gt;&lt;DIV&gt;&lt;DIV class="mceNonEditable lia-copypaste-placeholder"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class="mceNonEditable lia-copypaste-placeholder"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class="mceNonEditable lia-copypaste-placeholder"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;img /&gt;&lt;DIV class="mceNonEditable lia-copypaste-placeholder"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class="mceNonEditable lia-copypaste-placeholder"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;img /&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;DIV class="mceNonEditable lia-copypaste-placeholder"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;/DIV&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 21 Jul 2020 14:44:15 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DATEDIFF-as-DAX-Measure/m-p/1238773#M20280</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2020-07-21T14:44:15Z</dc:date>
    </item>
    <item>
      <title>Re: DATEDIFF as DAX Measure</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DATEDIFF-as-DAX-Measure/m-p/1242405#M20379</link>
      <description>&lt;P&gt;Hello, hoping you can read my last reply and provide some assistance please. I have a hard deadline for this project and I'm really trying to deliver it. Thank you!&lt;/P&gt;</description>
      <pubDate>Wed, 22 Jul 2020 16:18:05 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DATEDIFF-as-DAX-Measure/m-p/1242405#M20379</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2020-07-22T16:18:05Z</dc:date>
    </item>
    <item>
      <title>Re: DATEDIFF as DAX Measure</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DATEDIFF-as-DAX-Measure/m-p/1243269#M20400</link>
      <description>&lt;P&gt;You could try either of these measure expressions&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;TimeDiff = SUMX(Table, Table[TimeColumn1] - Table[TimeColumn2]&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;or&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;TimeDiff = SUMX(Table, DATEDIFF(Table[TimeColumn1], Table[TimeColumn2], MINUTE))&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;If you make a table visual with both time columns, you should see the difference when you add the measure.&amp;nbsp; Or you could use the aggregate, maybe switching to AVERAGEX, MAXX, etc. depending on what you are looking for.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Also, there are probably more impactful ways to reduce the file size of your model.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;If this works for you, please mark it as the solution.&amp;nbsp; Kudos are appreciated too.&amp;nbsp; Please let me know if not.&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Pat&lt;/P&gt;</description>
      <pubDate>Thu, 23 Jul 2020 00:41:18 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DATEDIFF-as-DAX-Measure/m-p/1243269#M20400</guid>
      <dc:creator>mahoneypat</dc:creator>
      <dc:date>2020-07-23T00:41:18Z</dc:date>
    </item>
    <item>
      <title>Re: DATEDIFF as DAX Measure</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DATEDIFF-as-DAX-Measure/m-p/1245146#M20432</link>
      <description>&lt;P&gt;Second measure worked using MAXX. Thank you very much!!!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Additionally, could you tell me what are the best ways to substantially reduce file size?&lt;/P&gt;</description>
      <pubDate>Thu, 23 Jul 2020 13:14:44 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DATEDIFF-as-DAX-Measure/m-p/1245146#M20432</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2020-07-23T13:14:44Z</dc:date>
    </item>
  </channel>
</rss>

