<?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: Card Graph that will show top 1, 3,and 5 based on a category with a date filter in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Card-Graph-that-will-show-top-1-3-and-5-based-on-a-category-with/m-p/2498236#M68993</link>
    <description>&lt;P&gt;Make it all dymamic&lt;/P&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Fri, 06 May 2022 09:32:29 GMT</pubDate>
    <dc:creator>CNENFRNL</dc:creator>
    <dc:date>2022-05-06T09:32:29Z</dc:date>
    <item>
      <title>Card Graph that will show top 1, 3,and 5 based on a category with a date filter</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Card-Graph-that-will-show-top-1-3-and-5-based-on-a-category-with/m-p/2497808#M68973</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have a table that looks like this:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;TABLE&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;Report Date&lt;/TD&gt;&lt;TD&gt;Country&lt;/TD&gt;&lt;TD&gt;Amount&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;09/31/2021&lt;/TD&gt;&lt;TD&gt;Country1&lt;/TD&gt;&lt;TD&gt;1000&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;09/31/2021&lt;/TD&gt;&lt;TD&gt;Country1&lt;/TD&gt;&lt;TD&gt;2000&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;09/31/2021&lt;/TD&gt;&lt;TD&gt;Country2&lt;/TD&gt;&lt;TD&gt;3000&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;09/31/2021&lt;/TD&gt;&lt;TD&gt;Country2&lt;/TD&gt;&lt;TD&gt;1000&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;09/31/2021&lt;/TD&gt;&lt;TD&gt;Country3&lt;/TD&gt;&lt;TD&gt;5000&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;09/31/2021&lt;/TD&gt;&lt;TD&gt;Country3&lt;/TD&gt;&lt;TD&gt;1000&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;09/31/2021&lt;/TD&gt;&lt;TD&gt;Country4&lt;/TD&gt;&lt;TD&gt;7000&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;09/31/2021&lt;/TD&gt;&lt;TD&gt;Country4&lt;/TD&gt;&lt;TD&gt;8000&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;09/31/2021&lt;/TD&gt;&lt;TD&gt;Country5&lt;/TD&gt;&lt;TD&gt;1000&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;09/31/2021&lt;/TD&gt;&lt;TD&gt;Country5&lt;/TD&gt;&lt;TD&gt;1000&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;07/30/2021&lt;/TD&gt;&lt;TD&gt;Country1&lt;/TD&gt;&lt;TD&gt;5000&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;07/30/2021&lt;/TD&gt;&lt;TD&gt;Country1&lt;/TD&gt;&lt;TD&gt;1000&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;07/30/2021&lt;/TD&gt;&lt;TD&gt;Country2&lt;/TD&gt;&lt;TD&gt;7000&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;07/30/2021&lt;/TD&gt;&lt;TD&gt;Country2&lt;/TD&gt;&lt;TD&gt;8000&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;07/30/2021&lt;/TD&gt;&lt;TD&gt;Country3&lt;/TD&gt;&lt;TD&gt;1000&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;07/30/2021&lt;/TD&gt;&lt;TD&gt;Country3&lt;/TD&gt;&lt;TD&gt;1000&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;07/30/2021&lt;/TD&gt;&lt;TD&gt;Country4&lt;/TD&gt;&lt;TD&gt;1000&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;07/30/2021&lt;/TD&gt;&lt;TD&gt;Country4&lt;/TD&gt;&lt;TD&gt;2000&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;07/30/2021&lt;/TD&gt;&lt;TD&gt;Country5&lt;/TD&gt;&lt;TD&gt;3000&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;07/30/2021&lt;/TD&gt;&lt;TD&gt;Country5&lt;/TD&gt;&lt;TD&gt;1000&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;TABLE&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;Report Date&lt;/TD&gt;&lt;TD&gt;09/31/2021&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;&amp;nbsp;&lt;/TD&gt;&lt;TD&gt;&amp;nbsp;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;Country1&lt;/TD&gt;&lt;TD&gt;3000&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;Country2&lt;/TD&gt;&lt;TD&gt;4000&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;Country3&lt;/TD&gt;&lt;TD&gt;6000&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;Country4&lt;/TD&gt;&lt;TD&gt;15000&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;Country5&lt;/TD&gt;&lt;TD&gt;2000&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I would like to create individual card graphs that will show the top 1 (Country4), 3 (Country3) and 5 Country5). I'm also using a Date Slicer to check out whos the top 5 in previous reports.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The country entries spans up to more than 20 so its important to get the top 1, 3 and 5. I thought i can get away with using the Filters on this Visual option but it only allows us to use one filter for the Country column.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks in advance!&lt;/P&gt;</description>
      <pubDate>Fri, 06 May 2022 06:59:48 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Card-Graph-that-will-show-top-1-3-and-5-based-on-a-category-with/m-p/2497808#M68973</guid>
      <dc:creator>delithyotho</dc:creator>
      <dc:date>2022-05-06T06:59:48Z</dc:date>
    </item>
    <item>
      <title>Re: Card Graph that will show top 1, 3,and 5 based on a category with a date filter</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Card-Graph-that-will-show-top-1-3-and-5-based-on-a-category-with/m-p/2497977#M68980</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="386185" data-lia-user-login="delithyotho" class="lia-mention lia-mention-user"&gt;delithyotho&lt;/a&gt;&amp;nbsp;&lt;BR /&gt;Here is a sample file with the solution&amp;nbsp;&lt;A href="https://we.tl/t-m7TsF2A4fU" target="_blank"&gt;https://we.tl/t-m7TsF2A4fU&lt;/A&gt;&lt;BR /&gt;I hope this is what you're looking for&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;Sales Amount = SUM ( Sales[Amount] )&lt;/LI-CODE&gt;&lt;LI-CODE lang="javascript"&gt;Top 3 Odd Ranking = 
VAR SummaryTable = SUMMARIZE ( Sales, Sales[Country], "@Amount", [Sales Amount] )
VAR RankingTable = ADDCOLUMNS ( SummaryTable, "@Ranking", RANKX ( SummaryTable, [@Amount] ) )
VAR FilteredTable = FILTER ( RankingTable, ISODD ( [@Ranking] ) )
RETURN
    CONCATENATEX ( FilteredTable, [Country], UNICHAR(10), [@Ranking], ASC )&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 06 May 2022 08:01:32 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Card-Graph-that-will-show-top-1-3-and-5-based-on-a-category-with/m-p/2497977#M68980</guid>
      <dc:creator>tamerj1</dc:creator>
      <dc:date>2022-05-06T08:01:32Z</dc:date>
    </item>
    <item>
      <title>Re: Card Graph that will show top 1, 3,and 5 based on a category with a date filter</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Card-Graph-that-will-show-top-1-3-and-5-based-on-a-category-with/m-p/2498236#M68993</link>
      <description>&lt;P&gt;Make it all dymamic&lt;/P&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 06 May 2022 09:32:29 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Card-Graph-that-will-show-top-1-3-and-5-based-on-a-category-with/m-p/2498236#M68993</guid>
      <dc:creator>CNENFRNL</dc:creator>
      <dc:date>2022-05-06T09:32:29Z</dc:date>
    </item>
    <item>
      <title>Re: Card Graph that will show top 1, 3,and 5 based on a category with a date filter</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Card-Graph-that-will-show-top-1-3-and-5-based-on-a-category-with/m-p/2503522#M69273</link>
      <description>&lt;P&gt;Hi,&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="386185" data-lia-user-login="delithyotho" class="lia-mention lia-mention-user"&gt;delithyotho&lt;/a&gt;&amp;nbsp;;&lt;/P&gt;
&lt;P&gt;You could create a measure.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="java"&gt;rank = RANKX(ALLSELECTED('Table (2)'),CALCULATE( CALCULATE(SUM([Amount]),FILTER(ALLSELECTED('Table (2)'),[Country]=MAX([Country])))),,DESC,Dense)&lt;/LI-CODE&gt;&lt;LI-CODE lang="java"&gt;top = "TOP1 : "&amp;amp; CALCULATE(MAX([Country]),FILTER('Table (2)',[rank]=1)) 
      &amp;amp;UNICHAR(10)&amp;amp;"TOP3 : "&amp;amp; CALCULATE(MAX([Country]),FILTER('Table (2)',[rank]=3))
      &amp;amp;UNICHAR(10)&amp;amp;"TOP5 : "&amp;amp; CALCULATE(MAX([Country]),FILTER('Table (2)',[rank]=5))&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The final output is shown below:&lt;/P&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;Best Regards,&lt;BR /&gt;Community Support Team _ Yalan Wu&lt;BR /&gt;If this post &lt;STRONG&gt;&lt;I&gt;helps&lt;/I&gt;&lt;/STRONG&gt;, then please consider &lt;STRONG&gt;&lt;I&gt;Accept it as the solution&lt;/I&gt;&lt;/STRONG&gt; to help the other members find it more quickly.&lt;/P&gt;</description>
      <pubDate>Tue, 10 May 2022 05:40:31 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Card-Graph-that-will-show-top-1-3-and-5-based-on-a-category-with/m-p/2503522#M69273</guid>
      <dc:creator>v-yalanwu-msft</dc:creator>
      <dc:date>2022-05-10T05:40:31Z</dc:date>
    </item>
  </channel>
</rss>

