<?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 DAX Measures for counting time differencies by speed category in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-Measures-for-counting-time-differencies-by-speed-category/m-p/2715107#M82639</link>
    <description>&lt;P&gt;Hello Community,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am trying to calculate through only DAX Measures the quantity of tickets being responded in 4 categories of speed (Difference between the timestamp of ticket creation minus the timestamp of ticket_start_to_resolve) :&lt;/P&gt;&lt;P&gt;&amp;lt;1 minute, 1 to 5 minutes, 5 to 60 minutes, &amp;gt;1 Hour&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;What I have&lt;/STRONG&gt; &lt;STRONG&gt;tried until now &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;1.-&lt;/STRONG&gt; Perform a measurement called SpeedResponse&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&lt;EM&gt;SpeedResponse = SUMX(factTable, 'factTable[ticket_response_timestamp] -&amp;nbsp;'factTable[ticket_creation_timestamp])&lt;/EM&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;2.-&lt;/STRONG&gt; (integration of 2.- and 3.- former steps into one Measurement).&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;lt;1 min_total =&amp;nbsp;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;//I know the following is not working, but in that way you will see the idea behind calculating the total of rows (tickets) with specific speed so that I can count them and then filter that total ammount with the additional filters later.&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;var _lessThan1Minute = COUNTX(factTable,&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&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; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;CALCULATE([SpeedResponse], IF(AND(HOUR([SpeedResponse])=0, MINUTE([SpeedResponse])&amp;lt;1),1,0))&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&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; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;)&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;var _lessthan1MinuteFiltered =&amp;nbsp;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;CALCULATE(_lessThan1Minute),&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;FILTER(ALL(factTable[ticketOrigin]),&amp;nbsp;ALL(factTable[ticketOrigin]="outsourcing")&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;return&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;_lessthan1MinuteFiltered&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you so much in advance community!&lt;/P&gt;</description>
    <pubDate>Sun, 21 Aug 2022 20:07:47 GMT</pubDate>
    <dc:creator>JasserBI</dc:creator>
    <dc:date>2022-08-21T20:07:47Z</dc:date>
    <item>
      <title>DAX Measures for counting time differencies by speed category</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-Measures-for-counting-time-differencies-by-speed-category/m-p/2715107#M82639</link>
      <description>&lt;P&gt;Hello Community,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am trying to calculate through only DAX Measures the quantity of tickets being responded in 4 categories of speed (Difference between the timestamp of ticket creation minus the timestamp of ticket_start_to_resolve) :&lt;/P&gt;&lt;P&gt;&amp;lt;1 minute, 1 to 5 minutes, 5 to 60 minutes, &amp;gt;1 Hour&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;What I have&lt;/STRONG&gt; &lt;STRONG&gt;tried until now &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;1.-&lt;/STRONG&gt; Perform a measurement called SpeedResponse&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&lt;EM&gt;SpeedResponse = SUMX(factTable, 'factTable[ticket_response_timestamp] -&amp;nbsp;'factTable[ticket_creation_timestamp])&lt;/EM&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;2.-&lt;/STRONG&gt; (integration of 2.- and 3.- former steps into one Measurement).&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;lt;1 min_total =&amp;nbsp;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;//I know the following is not working, but in that way you will see the idea behind calculating the total of rows (tickets) with specific speed so that I can count them and then filter that total ammount with the additional filters later.&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;var _lessThan1Minute = COUNTX(factTable,&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&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; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;CALCULATE([SpeedResponse], IF(AND(HOUR([SpeedResponse])=0, MINUTE([SpeedResponse])&amp;lt;1),1,0))&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&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; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;)&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;var _lessthan1MinuteFiltered =&amp;nbsp;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;CALCULATE(_lessThan1Minute),&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;FILTER(ALL(factTable[ticketOrigin]),&amp;nbsp;ALL(factTable[ticketOrigin]="outsourcing")&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;return&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;_lessthan1MinuteFiltered&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you so much in advance community!&lt;/P&gt;</description>
      <pubDate>Sun, 21 Aug 2022 20:07:47 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-Measures-for-counting-time-differencies-by-speed-category/m-p/2715107#M82639</guid>
      <dc:creator>JasserBI</dc:creator>
      <dc:date>2022-08-21T20:07:47Z</dc:date>
    </item>
    <item>
      <title>Re: DAX Measures for counting time differencies by speed category</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-Measures-for-counting-time-differencies-by-speed-category/m-p/2715593#M82667</link>
      <description>&lt;P&gt;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="429519" data-lia-user-login="JasserBI" class="lia-mention lia-mention-user"&gt;JasserBI&lt;/a&gt; , Have 4 measure like &lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;SpeedResponse = SUMX(filter(factTable, Datediff( 'factTable'[ticket_creation_timestamp],'factTable'[ticket_response_timestamp] , minute) &amp;lt;1),&lt;BR /&gt;Datediff( 'factTable'[ticket_creation_timestamp],'factTable'[ticket_response_timestamp] , minute) )&lt;/P&gt;
&lt;P&gt;of create one like&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;SpeedResponse = maxx(factTable, var _diff =Datediff( 'factTable'[ticket_creation_timestamp],'factTable'[ticket_response_timestamp] , minute)&lt;BR /&gt;Switch( True() ,&lt;BR /&gt;_diff &amp;lt; 1 , " &amp;lt; 1 Minute" ,&lt;BR /&gt;_diff &amp;lt; 5 , " 1 to 5 minutes" ,&lt;BR /&gt;_diff &amp;lt; 60 , " 5 to 60 minutes" , "&amp;gt;1 Hour"&lt;BR /&gt;) )&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Consider Segmentation&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Dynamic Segmentation Bucketing Binning&lt;BR /&gt;&lt;A href="https://community.powerbi.com/t5/Quick-Measures-Gallery/Dynamic-Segmentation-Bucketing-Binning/m-p/1387187#M626" target="_blank"&gt;https://community.powerbi.com/t5/Quick-Measures-Gallery/Dynamic-Segmentation-Bucketing-Binning/m-p/1387187#M626&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;Dynamic Segmentation, Bucketing or Binning: &lt;A href="https://youtu.be/CuczXPj0N-k" target="_blank"&gt;https://youtu.be/CuczXPj0N-k&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 22 Aug 2022 03:56:49 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-Measures-for-counting-time-differencies-by-speed-category/m-p/2715593#M82667</guid>
      <dc:creator>amitchandak</dc:creator>
      <dc:date>2022-08-22T03:56:49Z</dc:date>
    </item>
    <item>
      <title>Re: DAX Measures for counting time differencies by speed category</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-Measures-for-counting-time-differencies-by-speed-category/m-p/2735056#M83866</link>
      <description>&lt;P&gt;Hello&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="148838" data-lia-user-login="amitchandak" class="lia-mention lia-mention-user"&gt;amitchandak&lt;/a&gt;,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you for your response. It helped me to finally arrive to solution which consists in two steps:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;1.- Creating a measure of the time difference in an AVERAGEX iterator.&lt;/P&gt;&lt;P&gt;2.- Using with CALCULATE that formula filtered with the rest of parameters to consider and the columns involved with the condition of that measure in each category &amp;gt;1min&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 30 Aug 2022 11:06:39 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-Measures-for-counting-time-differencies-by-speed-category/m-p/2735056#M83866</guid>
      <dc:creator>JasserBI</dc:creator>
      <dc:date>2022-08-30T11:06:39Z</dc:date>
    </item>
  </channel>
</rss>

