<?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: URGENT!! Dax query giving blank in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/URGENT-Dax-query-giving-blank/m-p/3840396#M150143</link>
    <description>&lt;P&gt;Thanks a lot!&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="317289" data-lia-user-login="tamerj1" class="lia-mention lia-mention-user"&gt;tamerj1&lt;/a&gt;&amp;nbsp;for the solution.,&lt;/P&gt;</description>
    <pubDate>Tue, 16 Apr 2024 07:49:11 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2024-04-16T07:49:11Z</dc:date>
    <item>
      <title>URGENT!! Dax query giving blank</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/URGENT-Dax-query-giving-blank/m-p/3838654#M150071</link>
      <description>&lt;P&gt;Hello, Power Bi community,&amp;nbsp;&lt;/P&gt;&lt;P&gt;I need help with this Dax query below: here is the sample pbix as well:&amp;nbsp;&lt;A href="https://drive.google.com/file/d/1AC0jrk_w7ik0mX34jKGTzE7cI49ySkNI/view?usp=sharing" target="_self"&gt;https://drive.google.com/file/d/1AC0jrk_w7ik0mX34jKGTzE7cI49ySkNI/view?usp=sharing&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm getting blank when I run this code, can you help me I can get the correct data:&lt;/P&gt;&lt;P&gt;The expected output for this is 0.3%.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;Latest 4 Weeks %Contribution (Red) = 
CALCULATE(
    [Latest 4 Weeks %Contribution],
    FILTER(
        'Data by Channels',
        'Data by Channels'[L4W PP %Cont Color] = "Red" &amp;amp;&amp;amp;
        'Data by Channels'[State] &amp;lt;&amp;gt; "Total US" &amp;amp;&amp;amp;
        'Data by Channels'[State] &amp;lt;&amp;gt; "Core 7 States"
    )
)&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;the dependent queries are below:&amp;nbsp;&lt;BR /&gt;Latest 4 Weeks %Contribution:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;Latest 4 Weeks %Contribution = 
DIVIDE(
    SUM('Data by Channels'[Latest 4 Weeks Ending]), 
    CALCULATE(SUM('Data by Channels'[Latest 4 Weeks Ending]), 'Data by Channels'[State] = "Total US")
) &lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;L4W PP %Cont Color:&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;L4W PP %Cont Color = 
SWITCH ( 
    TRUE(),
    Max('Data by Channels'[Measures]) = "Value Share" || Max('Data by Channels'[Measures]) = "Volume Share (UC)" || Max('Data by Channels'[Measures]) = "Trial (% HH Buying, 1x)" || Max('Data by Channels'[Measures]) = "Average Weekly ACV Distribution" || Max('Data by Channels'[Measures]) = "Volume Segment" || Max('Data by Channels'[Measures]) = "Dollar Segment" || Max('Data by Channels'[Measures]) = "Repeaters (% HH Buying, 2x)" || Max('Data by Channels'[Measures]) = "Household Penetration" || CONTAINSSTRING(Max('Data by Channels'[Measures]), "Average Weekly CWD Distribution") || CONTAINSSTRING(Max('Data by Channels'[Measures]), "Volume Sales (UC) by Merch"), 
        IF(
            SUM('Data by Channels'[Latest 4 Weeks Ending]) - SUM('Data by Channels'[Previous Period 4 weeks]) &amp;lt; 0,
            "Red",
            IF(
                SUM('Data by Channels'[Previous Period 4 weeks]) = 0,
                "Grey",
                "Green"
            )
        ),
    TRUE(), 
        IF(
            (SUM('Data by Channels'[Latest 4 Weeks Ending])/SUM('Data by Channels'[Previous Period 4 weeks])-1) &amp;lt; 0,
            "Red",
            IF(
                SUM('Data by Channels'[Previous Period 4 weeks]) = 0,
                "Grey",
                "Green"
            )
        )
)&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Please take a look and let me know if you need anything else.&lt;BR /&gt;Look forward to your replies.&lt;/P&gt;&lt;P&gt;&lt;A href="https://community.fabric.microsoft.com/t5/user/viewprofilepage/user-id/14361" target="_blank" rel="noopener"&gt;@MFelix&lt;/A&gt;&lt;SPAN&gt;&amp;nbsp;,&amp;nbsp;&lt;/SPAN&gt;&lt;A href="https://community.fabric.microsoft.com/t5/user/viewprofilepage/user-id/148838" target="_blank" rel="noopener"&gt;@amitchandak&lt;/A&gt;&lt;SPAN&gt;&amp;nbsp;,&amp;nbsp;&lt;/SPAN&gt;&lt;A href="https://community.fabric.microsoft.com/t5/user/viewprofilepage/user-id/19851" target="_blank" rel="noopener"&gt;@Ashish_Mathur&lt;/A&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 16 Apr 2024 02:20:01 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/URGENT-Dax-query-giving-blank/m-p/3838654#M150071</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2024-04-16T02:20:01Z</dc:date>
    </item>
    <item>
      <title>Re: URGENT!! Dax query giving blank</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/URGENT-Dax-query-giving-blank/m-p/3838722#M150073</link>
      <description>&lt;P&gt;Anonymous&lt;/a&gt;&amp;nbsp;Sample data would be of tremendous help here.&amp;nbsp;Sorry, having trouble following, can you post sample data as text and expected output?&lt;BR /&gt;Not really enough information to go on, please first check if your issue is a common issue listed here: &lt;A href="https://community.powerbi.com/t5/Community-Blog/Before-You-Post-Read-This/ba-p/1116882" target="_blank"&gt;https://community.powerbi.com/t5/Community-Blog/Before-You-Post-Read-This/ba-p/1116882&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;Also, please see this post regarding How to Get Your Question Answered Quickly: &lt;A href="https://community.powerbi.com/t5/Community-Blog/How-to-Get-Your-Question-Answered-Quickly/ba-p/38490" target="_blank"&gt;https://community.powerbi.com/t5/Community-Blog/How-to-Get-Your-Question-Answered-Quickly/ba-p/38490&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;The most important parts are:&lt;BR /&gt;1. Sample data as text, use the table tool in the editing bar&lt;BR /&gt;2. Expected output from sample data&lt;BR /&gt;3. Explanation in words of how to get from 1. to 2.&lt;/P&gt;</description>
      <pubDate>Mon, 15 Apr 2024 15:40:31 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/URGENT-Dax-query-giving-blank/m-p/3838722#M150073</guid>
      <dc:creator>Greg_Deckler</dc:creator>
      <dc:date>2024-04-15T15:40:31Z</dc:date>
    </item>
    <item>
      <title>Re: URGENT!! Dax query giving blank</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/URGENT-Dax-query-giving-blank/m-p/3839507#M150107</link>
      <description>&lt;P&gt;Hello&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="313" data-lia-user-login="Greg_Deckler" class="lia-mention lia-mention-user"&gt;Greg_Deckler&lt;/a&gt;&amp;nbsp;&lt;BR /&gt;Thank you for the suggestion, I've attached the sample pbix and the expected output to the original post. Please take a look at this. and let me know.&lt;/P&gt;</description>
      <pubDate>Tue, 16 Apr 2024 02:21:20 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/URGENT-Dax-query-giving-blank/m-p/3839507#M150107</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2024-04-16T02:21:20Z</dc:date>
    </item>
    <item>
      <title>Re: URGENT!! Dax query giving blank</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/URGENT-Dax-query-giving-blank/m-p/3840345#M150141</link>
      <description>&lt;P&gt;Hi&amp;nbsp;Anonymous&lt;/a&gt;&amp;nbsp;&lt;BR /&gt;&amp;nbsp;Following a proposed solution&lt;/P&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;LI-CODE lang="javascript"&gt;Latest 4 Weeks %Contribution (Red) = 
SUMX ( 
    FILTER(
        VALUES ( 'Data by Channels'[State] ),
        NOT 'Data by Channels'[State] IN { "Total US", "Core 7 States" } 
            &amp;amp;&amp;amp; [L4W PP %Cont Color] = "Red"
    ),
    [Latest 4 Weeks %Contribution]
)&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 16 Apr 2024 07:38:43 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/URGENT-Dax-query-giving-blank/m-p/3840345#M150141</guid>
      <dc:creator>tamerj1</dc:creator>
      <dc:date>2024-04-16T07:38:43Z</dc:date>
    </item>
    <item>
      <title>Re: URGENT!! Dax query giving blank</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/URGENT-Dax-query-giving-blank/m-p/3840396#M150143</link>
      <description>&lt;P&gt;Thanks a lot!&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="317289" data-lia-user-login="tamerj1" class="lia-mention lia-mention-user"&gt;tamerj1&lt;/a&gt;&amp;nbsp;for the solution.,&lt;/P&gt;</description>
      <pubDate>Tue, 16 Apr 2024 07:49:11 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/URGENT-Dax-query-giving-blank/m-p/3840396#M150143</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2024-04-16T07:49:11Z</dc:date>
    </item>
  </channel>
</rss>

