<?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: Query has exceeded available resources in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Query-has-exceeded-available-resources/m-p/4376947#M173777</link>
    <description>&lt;P&gt;&lt;FONT&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="858560" data-lia-user-login="MrBlueSky2" class="lia-mention lia-mention-user"&gt;MrBlueSky2&lt;/a&gt;&lt;/FONT&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thank you very much&amp;nbsp;Kedar_Pande&amp;nbsp;and Sahir_Maharaj&amp;nbsp;for your prompt reply.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;I'm glad to hear you found a solution! It sounds like using the&amp;nbsp;SUMX&lt;/SPAN&gt;&lt;SPAN&gt;&amp;nbsp;function with a recalculated margin and an IF&lt;/SPAN&gt;&lt;SPAN&gt;&amp;nbsp;statement was the key. Sometimes, more complex formulas can indeed be more efficient, depending on how they interact with the data model and the engine's optimization.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;You can accept it as a solution, which will help to help more people understand the problem.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Regards,&lt;/P&gt;
&lt;P&gt;Nono Chen&lt;/P&gt;
&lt;P&gt;If this &lt;STRONG&gt;&lt;EM&gt;post&lt;/EM&gt;&lt;/STRONG&gt;&amp;nbsp;helps, then please consider&amp;nbsp;&lt;STRONG&gt;&lt;EM&gt;Accept it as the solution&lt;/EM&gt;&lt;/STRONG&gt;&amp;nbsp;to help the other members find it more quickly.&lt;/P&gt;</description>
    <pubDate>Thu, 23 Jan 2025 06:00:12 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2025-01-23T06:00:12Z</dc:date>
    <item>
      <title>Query has exceeded available resources</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Query-has-exceeded-available-resources/m-p/4373750#M173654</link>
      <description>&lt;P&gt;Hi all,&lt;BR /&gt;&lt;BR /&gt;I try to filter a table based on a field parameter value to show only the rows with margin below the selected value.&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;The regular filter visual does not allow to use a field parameter but only hard coded values.&lt;BR /&gt;&lt;BR /&gt;So I tried to use a calculated column with a true/false based on the field parameter but it only compares to the default value, I assume it is assessed only at table load&lt;BR /&gt;&lt;BR /&gt;I tried then to create a measure with true/false based on the field parameter however I get the error "the query has exceeded the available resources"&lt;BR /&gt;&lt;BR /&gt;Even when I add the field parameter to the table I get this error, it is simply a scalar value so I don't understand why the engine is getting stuck with this. I even tried to create a measure with a constant value "1" and add it to the table and I get the same error.&lt;BR /&gt;&lt;BR /&gt;Any help with this?&lt;BR /&gt;&lt;BR /&gt;BR&lt;/P&gt;</description>
      <pubDate>Tue, 21 Jan 2025 13:45:04 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Query-has-exceeded-available-resources/m-p/4373750#M173654</guid>
      <dc:creator>MrBlueSky2</dc:creator>
      <dc:date>2025-01-21T13:45:04Z</dc:date>
    </item>
    <item>
      <title>Re: Query has exceeded available resources</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Query-has-exceeded-available-resources/m-p/4374226#M173681</link>
      <description>&lt;P&gt;Hello&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="858560" data-lia-user-login="MrBlueSky2" class="lia-mention lia-mention-user"&gt;MrBlueSky2&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Instead of calculating True/False for each row dynamically with a measure, you can rewrite your measure to focus only on filtering the rows:&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;Filter Measure = 
VAR SelectedMargin = SELECTEDVALUE(FieldParameterTable[FieldParameter])
RETURN
    IF( MAX(TableName[Margin]) &amp;lt; SelectedMargin, 1, 0 )
&lt;/LI-CODE&gt;</description>
      <pubDate>Tue, 21 Jan 2025 18:40:07 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Query-has-exceeded-available-resources/m-p/4374226#M173681</guid>
      <dc:creator>Sahir_Maharaj</dc:creator>
      <dc:date>2025-01-21T18:40:07Z</dc:date>
    </item>
    <item>
      <title>Re: Query has exceeded available resources</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Query-has-exceeded-available-resources/m-p/4375449#M173716</link>
      <description>&lt;P&gt;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="858560" data-lia-user-login="MrBlueSky2" class="lia-mention lia-mention-user"&gt;MrBlueSky2&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Create a Measure:&lt;/P&gt;
&lt;PRE&gt;FilterMeasure = &lt;BR /&gt;IF(&lt;BR /&gt;SELECTEDVALUE('YourFieldParameterTable'[FieldParameter]) &amp;gt; 0 &amp;amp;&amp;amp;&lt;BR /&gt;MAX('YourTable'[Margin]) &amp;lt; SELECTEDVALUE('YourFieldParameterTable'[FieldParameter]),&lt;BR /&gt;1,&lt;BR /&gt;0&lt;BR /&gt;)&lt;/PRE&gt;
&lt;P&gt;Add this measure to your visual and set the filter to FilterMeasure = 1&lt;/P&gt;
&lt;P&gt;If performance issues persist, simplify your data model or reduce the visual complexity by pre-aggregating data.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;DIV&gt;&lt;span class="lia-unicode-emoji" title=":light_bulb:"&gt;💡&lt;/span&gt; &lt;STRONG&gt;If this helped, please give Kudos &lt;span class="lia-unicode-emoji" title=":thumbs_up:"&gt;👍&lt;/span&gt; or mark it as a Solution &lt;span class="lia-unicode-emoji" title=":white_heavy_check_mark:"&gt;✅&lt;/span&gt;.&lt;/STRONG&gt;&lt;BR /&gt;&lt;EM&gt;Best regards,&lt;BR /&gt;&lt;STRONG&gt;Kedar&lt;/STRONG&gt;&lt;EM&gt;&lt;BR /&gt;&lt;A href="https://www.linkedin.com/in/kedar-pande" target="_blank"&gt;&lt;span class="lia-unicode-emoji" title=":globe_with_meridians:"&gt;🌐&lt;/span&gt; Connect on LinkedIn&lt;/A&gt;&lt;BR /&gt;&lt;/EM&gt;&lt;/EM&gt;&lt;/DIV&gt;</description>
      <pubDate>Wed, 22 Jan 2025 10:23:27 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Query-has-exceeded-available-resources/m-p/4375449#M173716</guid>
      <dc:creator>Kedar_Pande</dc:creator>
      <dc:date>2025-01-22T10:23:27Z</dc:date>
    </item>
    <item>
      <title>Re: Query has exceeded available resources</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Query-has-exceeded-available-resources/m-p/4376481#M173764</link>
      <description>&lt;P&gt;Thanks for your help both, unfortunately suggested solutions don't work but I found a way to fix it. I created a measure with a IF that returns 1 or 0 based on the parameter and a recalculated margin within a SUMX instead of using the precalculated margin field.&lt;BR /&gt;&lt;BR /&gt;It works now, the new formula is more complex but for some reason uses less resources&lt;/P&gt;</description>
      <pubDate>Wed, 22 Jan 2025 21:20:41 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Query-has-exceeded-available-resources/m-p/4376481#M173764</guid>
      <dc:creator>MrBlueSky2</dc:creator>
      <dc:date>2025-01-22T21:20:41Z</dc:date>
    </item>
    <item>
      <title>Re: Query has exceeded available resources</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Query-has-exceeded-available-resources/m-p/4376947#M173777</link>
      <description>&lt;P&gt;&lt;FONT&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="858560" data-lia-user-login="MrBlueSky2" class="lia-mention lia-mention-user"&gt;MrBlueSky2&lt;/a&gt;&lt;/FONT&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thank you very much&amp;nbsp;Kedar_Pande&amp;nbsp;and Sahir_Maharaj&amp;nbsp;for your prompt reply.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;I'm glad to hear you found a solution! It sounds like using the&amp;nbsp;SUMX&lt;/SPAN&gt;&lt;SPAN&gt;&amp;nbsp;function with a recalculated margin and an IF&lt;/SPAN&gt;&lt;SPAN&gt;&amp;nbsp;statement was the key. Sometimes, more complex formulas can indeed be more efficient, depending on how they interact with the data model and the engine's optimization.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;You can accept it as a solution, which will help to help more people understand the problem.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Regards,&lt;/P&gt;
&lt;P&gt;Nono Chen&lt;/P&gt;
&lt;P&gt;If this &lt;STRONG&gt;&lt;EM&gt;post&lt;/EM&gt;&lt;/STRONG&gt;&amp;nbsp;helps, then please consider&amp;nbsp;&lt;STRONG&gt;&lt;EM&gt;Accept it as the solution&lt;/EM&gt;&lt;/STRONG&gt;&amp;nbsp;to help the other members find it more quickly.&lt;/P&gt;</description>
      <pubDate>Thu, 23 Jan 2025 06:00:12 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Query-has-exceeded-available-resources/m-p/4376947#M173777</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2025-01-23T06:00:12Z</dc:date>
    </item>
    <item>
      <title>Re: Query has exceeded available resources</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Query-has-exceeded-available-resources/m-p/4376960#M173778</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="858560" data-lia-user-login="MrBlueSky2" class="lia-mention lia-mention-user"&gt;MrBlueSky2&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Please try using the below DAX:&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;IsBelowSelectedMargin = 
IF(
    MAX('Table'[Margin]) &amp;lt; SELECTEDVALUE('Field Parameter Table'[Field Parameter]),
    1, 
    0
)
&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;Reduce table size in Power Query.&lt;/LI&gt;
&lt;LI&gt;Simplify DAX formulas.&lt;/LI&gt;
&lt;LI&gt;Ensure correct relationships between tables.&lt;/LI&gt;
&lt;/UL&gt;
&lt;P&gt;&lt;!--StartFragment --&gt;&lt;/P&gt;
&lt;P&gt; &lt;/P&gt;
&lt;P&gt;&lt;!--EndFragment --&gt;&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;&lt;/P&gt;</description>
      <pubDate>Thu, 23 Jan 2025 06:06:32 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Query-has-exceeded-available-resources/m-p/4376960#M173778</guid>
      <dc:creator>Poojara_D12</dc:creator>
      <dc:date>2025-01-23T06:06:32Z</dc:date>
    </item>
  </channel>
</rss>

