<?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: Direct Query - WorkQueue / WorkQueueItems in Power Query</title>
    <link>https://community.fabric.microsoft.com/t5/Power-Query/Direct-Query-WorkQueue-WorkQueueItems/m-p/4144440#M136102</link>
    <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="691153" data-lia-user-login="hsiddiq" class="lia-mention lia-mention-user"&gt;hsiddiq&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thank you for reaching out. I understand you are trying to count the WorkQueueItemID where Statecode = 2 and CompletedOn is within the last 60 minutes, but you are facing challenges with the datetime conversion from UTC to AEST.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Firstly, I would like to ask if the suggestion provided by another user helped resolve your issue.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;For&amp;nbsp;counting calculation, you could try:&lt;/SPAN&gt;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;Processed_last60min =
CALCULATE(
    COUNT('workqueueitem'[workqueueitemid]),
    'workqueueitem'[statecode] = 2,
    'workqueueitem'[completedon] &amp;gt;= (CurrentTimeStampSydney - TIME(1, 0, 0))
)
&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;If the issue persists, could you please provide some sample data and the expected results? This will help us better understand the problem and provide a more accurate solution.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Best Regards,&lt;/P&gt;
&lt;P&gt;Stephen Tao&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&amp;nbsp;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;If this post&amp;nbsp;&lt;STRONG&gt;helps&lt;/STRONG&gt;, then please consider&amp;nbsp;&lt;STRONG&gt;Accept it as the solution&amp;nbsp;&lt;/STRONG&gt;to help the other members find it more quickly.&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Wed, 11 Sep 2024 08:19:47 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2024-09-11T08:19:47Z</dc:date>
    <item>
      <title>Direct Query - WorkQueue / WorkQueueItems</title>
      <link>https://community.fabric.microsoft.com/t5/Power-Query/Direct-Query-WorkQueue-WorkQueueItems/m-p/4136453#M135794</link>
      <description>&lt;P&gt;Hi team, if anyone can help me on this.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;In my dashboard, I have workqueue and workqueueitem Dataverse tables conencted via a Direct Query.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Trying to Count (sum) of all the WorkQueueItemID&lt;/P&gt;&lt;P&gt;where Statecode = 2&lt;/P&gt;&lt;P&gt;CompeltedOn in the Last 60 mins.&lt;BR /&gt;&lt;BR /&gt;Challenge,&amp;nbsp;&lt;BR /&gt;The CompeltedOn (datetime) is showing in UTC, I have already got CurrentTimeStampSydney which I can use as Now() time.&lt;BR /&gt;in a directQuery how can I convert CompletedOn to AUST time and then check how many are in this status for last 60 mins?&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;I've tried&amp;nbsp;&lt;BR /&gt;timeDifferent without any conversion, but failing to get the SUM/Count.&amp;nbsp;&lt;BR /&gt;Not sure where my query is going wrong.&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;1. workqueueitem[compeltedon] &amp;gt;= Now() + Time(0,60,0)&lt;BR /&gt;2. TimeDifference (workqueueitem[compeltedon] -&amp;nbsp;Now() + Time(0,60,0))&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;Processed_last60min =&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;CALCULATE&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;COUNT&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;'workqueueitem'&lt;/SPAN&gt;&lt;SPAN&gt;[workqueueitemid]&lt;/SPAN&gt;&lt;SPAN&gt;),&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;workqueueitem&lt;/SPAN&gt;&lt;SPAN&gt;[statecode]&lt;/SPAN&gt;&lt;SPAN&gt; = &lt;/SPAN&gt;&lt;SPAN&gt;2&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; //createdOn&amp;nbsp; in the last 60 mins&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp;)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;</description>
      <pubDate>Fri, 06 Sep 2024 01:48:50 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Power-Query/Direct-Query-WorkQueue-WorkQueueItems/m-p/4136453#M135794</guid>
      <dc:creator>hsiddiq</dc:creator>
      <dc:date>2024-09-06T01:48:50Z</dc:date>
    </item>
    <item>
      <title>Re: Direct Query - WorkQueue / WorkQueueItems</title>
      <link>https://community.fabric.microsoft.com/t5/Power-Query/Direct-Query-WorkQueue-WorkQueueItems/m-p/4137399#M135815</link>
      <description>&lt;P&gt;Hi!&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="691153" data-lia-user-login="hsiddiq" class="lia-mention lia-mention-user"&gt;hsiddiq&lt;/a&gt;&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;Try this&amp;nbsp;CompletedOn = Table1[CompletedOn] + TIME(10, 0, 0)&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 06 Sep 2024 10:50:39 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Power-Query/Direct-Query-WorkQueue-WorkQueueItems/m-p/4137399#M135815</guid>
      <dc:creator>AnkitKukreja</dc:creator>
      <dc:date>2024-09-06T10:50:39Z</dc:date>
    </item>
    <item>
      <title>Re: Direct Query - WorkQueue / WorkQueueItems</title>
      <link>https://community.fabric.microsoft.com/t5/Power-Query/Direct-Query-WorkQueue-WorkQueueItems/m-p/4144440#M136102</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="691153" data-lia-user-login="hsiddiq" class="lia-mention lia-mention-user"&gt;hsiddiq&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thank you for reaching out. I understand you are trying to count the WorkQueueItemID where Statecode = 2 and CompletedOn is within the last 60 minutes, but you are facing challenges with the datetime conversion from UTC to AEST.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Firstly, I would like to ask if the suggestion provided by another user helped resolve your issue.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;For&amp;nbsp;counting calculation, you could try:&lt;/SPAN&gt;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;Processed_last60min =
CALCULATE(
    COUNT('workqueueitem'[workqueueitemid]),
    'workqueueitem'[statecode] = 2,
    'workqueueitem'[completedon] &amp;gt;= (CurrentTimeStampSydney - TIME(1, 0, 0))
)
&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;If the issue persists, could you please provide some sample data and the expected results? This will help us better understand the problem and provide a more accurate solution.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Best Regards,&lt;/P&gt;
&lt;P&gt;Stephen Tao&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&amp;nbsp;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;If this post&amp;nbsp;&lt;STRONG&gt;helps&lt;/STRONG&gt;, then please consider&amp;nbsp;&lt;STRONG&gt;Accept it as the solution&amp;nbsp;&lt;/STRONG&gt;to help the other members find it more quickly.&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 11 Sep 2024 08:19:47 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Power-Query/Direct-Query-WorkQueue-WorkQueueItems/m-p/4144440#M136102</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2024-09-11T08:19:47Z</dc:date>
    </item>
  </channel>
</rss>

