<?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: Dax Question in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Dax-Question/m-p/3798179#M148454</link>
    <description>&lt;P&gt;Hi,&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="713934" data-lia-user-login="Rajesh_Vodela" class="lia-mention lia-mention-user"&gt;Rajesh_Vodela&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;&amp;nbsp;&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;Thank you very much for &lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="239577" data-lia-user-login="MattB-Motive" class="lia-mention lia-mention-user"&gt;MattB-Motive&lt;/a&gt;&amp;nbsp; reply. Based on your description, I have created some dax to achieve the effect you are looking for. Following picture shows the effect of the display.&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;DAX:&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;Method 1 = 
SWITCH (
    'Table'[Brand_Name],
    "5-Star", "Chocolates",
    "Daily Milk", "Chocolates",
    "Perk", "Chocolates",
    "Eclair", "Chocolates",
    "GoodDay", "Biscuits",
    "Boost", "Biscuits",
    "Britannia", "Biscuits",
    BLANK ()
)
&lt;/LI-CODE&gt;&lt;LI-CODE lang="markup"&gt;Method 2 = 
VAR _category = 'Table'[Brand_Name]
VAR _chocolatesGroup = { "5-Star", "Daily Milk", "Perk", "Eclair" }
VAR _biscuitsGroup = { "Britannia", "GoodDay", "Boost" }
RETURN
    IF (
        _category IN _chocolatesGroup,
        "Chocolates",
        IF ( _category IN _biscuitsGroup, "Biscuits" )
    )
&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;Best Regards,&lt;BR /&gt;Yang&lt;BR /&gt;Community Support Team&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If there is any post&amp;nbsp;&lt;STRONG&gt;&lt;EM&gt;helps&lt;/EM&gt;&lt;/STRONG&gt;, then please consider&amp;nbsp;&lt;STRONG&gt;&lt;EM&gt;Accept it as the solution&lt;/EM&gt;&lt;/STRONG&gt;&lt;STRONG&gt;&amp;nbsp;&amp;nbsp;&lt;/STRONG&gt;&lt;STRONG&gt;to&lt;/STRONG&gt; help the other members find it more quickly.&lt;BR /&gt;If I misunderstand your needs or you still have problems on it, please feel free to let us know.&amp;nbsp;&lt;STRONG&gt;&lt;EM&gt;Thanks a lot!&lt;/EM&gt;&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&lt;A href="https://community.powerbi.com/t5/Community-Blog/How-to-Get-Your-Question-Answered-Quickly/ba-p/38490" target="_blank" rel="noopener"&gt;How to get your questions answered quickly&lt;/A&gt;&amp;nbsp;--&amp;nbsp;&lt;A href="https://community.powerbi.com/t5/Community-Blog/How-to-provide-sample-data-in-the-Power-BI-Forum/ba-p/963216" target="_blank" rel="noopener"&gt;&amp;nbsp;How to provide sample data in the Power BI Forum&lt;/A&gt;&lt;/P&gt;</description>
    <pubDate>Mon, 01 Apr 2024 08:26:36 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2024-04-01T08:26:36Z</dc:date>
    <item>
      <title>Dax Question</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Dax-Question/m-p/3796859#M148386</link>
      <description>&lt;P&gt;I have a Input table(left table) which contains 2 columns named category and brand_name nad my output should be the right tableas shown in the image.&lt;BR /&gt;I want to fill down the values in category using dax.&lt;BR /&gt;Using power bi dax how can we write the query to fill down.&lt;BR /&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 28 Mar 2024 12:37:39 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Dax-Question/m-p/3796859#M148386</guid>
      <dc:creator>Rajesh_Vodela</dc:creator>
      <dc:date>2024-03-28T12:37:39Z</dc:date>
    </item>
    <item>
      <title>Re: Dax Question</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Dax-Question/m-p/3796996#M148392</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="713934" data-lia-user-login="Rajesh_Vodela" class="lia-mention lia-mention-user"&gt;Rajesh_Vodela&lt;/a&gt;&amp;nbsp;&lt;BR /&gt;Is there a reason you want to do this in DAX and not Power Query?&lt;/P&gt;&lt;P&gt;Power Query is one click, DAX will be complex.&lt;/P&gt;&lt;P&gt;&lt;A href="https://learn.microsoft.com/en-us/power-query/fill-values-column#fill-down" target="_blank"&gt;Fill values in a column - Power Query | Microsoft Learn&lt;/A&gt;&lt;/P&gt;&lt;P&gt;Just make sure the 'empty' cells are null before filling.&lt;/P&gt;</description>
      <pubDate>Thu, 28 Mar 2024 13:02:22 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Dax-Question/m-p/3796996#M148392</guid>
      <dc:creator>MattB-Motive</dc:creator>
      <dc:date>2024-03-28T13:02:22Z</dc:date>
    </item>
    <item>
      <title>Re: Dax Question</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Dax-Question/m-p/3797138#M148399</link>
      <description>&lt;P&gt;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="239577" data-lia-user-login="MattB-Motive" class="lia-mention lia-mention-user"&gt;MattB-Motive&lt;/a&gt;&amp;nbsp;&lt;BR /&gt;Actually this question was asked in an interview. And i was not aware of this. So, i want to know the solution that how can we do this in dax&lt;/P&gt;</description>
      <pubDate>Thu, 28 Mar 2024 14:23:41 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Dax-Question/m-p/3797138#M148399</guid>
      <dc:creator>Rajesh_Vodela</dc:creator>
      <dc:date>2024-03-28T14:23:41Z</dc:date>
    </item>
    <item>
      <title>Re: Dax Question</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Dax-Question/m-p/3798179#M148454</link>
      <description>&lt;P&gt;Hi,&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="713934" data-lia-user-login="Rajesh_Vodela" class="lia-mention lia-mention-user"&gt;Rajesh_Vodela&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;&amp;nbsp;&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;Thank you very much for &lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="239577" data-lia-user-login="MattB-Motive" class="lia-mention lia-mention-user"&gt;MattB-Motive&lt;/a&gt;&amp;nbsp; reply. Based on your description, I have created some dax to achieve the effect you are looking for. Following picture shows the effect of the display.&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;DAX:&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;Method 1 = 
SWITCH (
    'Table'[Brand_Name],
    "5-Star", "Chocolates",
    "Daily Milk", "Chocolates",
    "Perk", "Chocolates",
    "Eclair", "Chocolates",
    "GoodDay", "Biscuits",
    "Boost", "Biscuits",
    "Britannia", "Biscuits",
    BLANK ()
)
&lt;/LI-CODE&gt;&lt;LI-CODE lang="markup"&gt;Method 2 = 
VAR _category = 'Table'[Brand_Name]
VAR _chocolatesGroup = { "5-Star", "Daily Milk", "Perk", "Eclair" }
VAR _biscuitsGroup = { "Britannia", "GoodDay", "Boost" }
RETURN
    IF (
        _category IN _chocolatesGroup,
        "Chocolates",
        IF ( _category IN _biscuitsGroup, "Biscuits" )
    )
&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;Best Regards,&lt;BR /&gt;Yang&lt;BR /&gt;Community Support Team&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If there is any post&amp;nbsp;&lt;STRONG&gt;&lt;EM&gt;helps&lt;/EM&gt;&lt;/STRONG&gt;, then please consider&amp;nbsp;&lt;STRONG&gt;&lt;EM&gt;Accept it as the solution&lt;/EM&gt;&lt;/STRONG&gt;&lt;STRONG&gt;&amp;nbsp;&amp;nbsp;&lt;/STRONG&gt;&lt;STRONG&gt;to&lt;/STRONG&gt; help the other members find it more quickly.&lt;BR /&gt;If I misunderstand your needs or you still have problems on it, please feel free to let us know.&amp;nbsp;&lt;STRONG&gt;&lt;EM&gt;Thanks a lot!&lt;/EM&gt;&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&lt;A href="https://community.powerbi.com/t5/Community-Blog/How-to-Get-Your-Question-Answered-Quickly/ba-p/38490" target="_blank" rel="noopener"&gt;How to get your questions answered quickly&lt;/A&gt;&amp;nbsp;--&amp;nbsp;&lt;A href="https://community.powerbi.com/t5/Community-Blog/How-to-provide-sample-data-in-the-Power-BI-Forum/ba-p/963216" target="_blank" rel="noopener"&gt;&amp;nbsp;How to provide sample data in the Power BI Forum&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 01 Apr 2024 08:26:36 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Dax-Question/m-p/3798179#M148454</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2024-04-01T08:26:36Z</dc:date>
    </item>
  </channel>
</rss>

