<?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: Matrix - display 1 or -1 values based on a text field in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Matrix-display-1-or-1-values-based-on-a-text-field/m-p/3923172#M152672</link>
    <description>&lt;P&gt;&lt;FONT&gt;Hi&amp;nbsp;Anonymous&lt;/LI-USER&gt;&lt;/FONT&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks for the reply from &lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="583663" data-lia-user-login="Learner27" class="lia-mention lia-mention-user"&gt;Learner27&lt;/a&gt;&amp;nbsp;, please allow me to provide another insight:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;My sample:&lt;/P&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If you don't necessarily want to use a calculated column, try creating the following measure:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;Measure = IF(MAX([cancelled]) = BLANK(), CALCULATE(DISTINCTCOUNT('Table'[account]), ALLEXCEPT('Table', 'Table'[account])), -1)&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Output:&lt;/P&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If this sample data is structurally different from the one you are using, please do not hesitate to mention it and I will modify it.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Best Regards,&lt;BR /&gt;Yulia Xu&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If this post &lt;EM&gt;&lt;STRONG&gt;helps&lt;/STRONG&gt;&lt;/EM&gt;, then please consider &lt;EM&gt;&lt;STRONG&gt;Accept it as the solution&lt;/STRONG&gt;&lt;/EM&gt; to help the other members find it more quickly.&lt;/P&gt;</description>
    <pubDate>Thu, 16 May 2024 09:01:55 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2024-05-16T09:01:55Z</dc:date>
    <item>
      <title>Matrix - display 1 or -1 values based on a text field</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Matrix-display-1-or-1-values-based-on-a-text-field/m-p/3918372#M152520</link>
      <description>&lt;P&gt;I have a matrix displaying a series of columns, with the last column being a count of unique account numbers (summarizing on countd of those account numers)...So each row should have a 1 in that field.&amp;nbsp; &amp;nbsp;However, I would like to be able indicate a -1 if something cancelled.&amp;nbsp; &amp;nbsp;So I have a column that says if something is cancelled and is blank if it isn't.&amp;nbsp; &amp;nbsp;How can I get that COUNTD of account numbers in that row to be -1 for cancelled and 1 for non-cancelled.&amp;nbsp; I tried using IFs but they don't work&lt;/P&gt;</description>
      <pubDate>Tue, 14 May 2024 19:48:00 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Matrix-display-1-or-1-values-based-on-a-text-field/m-p/3918372#M152520</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2024-05-14T19:48:00Z</dc:date>
    </item>
    <item>
      <title>Re: Matrix - display 1 or -1 values based on a text field</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Matrix-display-1-or-1-values-based-on-a-text-field/m-p/3919459#M152566</link>
      <description>&lt;P&gt;Hi&amp;nbsp; have you tried to&amp;nbsp;create a new calculated column in your data table that assigns 1 for non-cancelled accounts and -1 for cancelled accounts.&lt;/P&gt;</description>
      <pubDate>Wed, 15 May 2024 06:44:22 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Matrix-display-1-or-1-values-based-on-a-text-field/m-p/3919459#M152566</guid>
      <dc:creator>Learner27</dc:creator>
      <dc:date>2024-05-15T06:44:22Z</dc:date>
    </item>
    <item>
      <title>Re: Matrix - display 1 or -1 values based on a text field</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Matrix-display-1-or-1-values-based-on-a-text-field/m-p/3920421#M152596</link>
      <description>&lt;P&gt;Yes but that doens't work because there are multiple rows for each account ID in some cases ... IE maybe 3 or 4 regular ones plus the one record that's cancelled, so the matrix sums them, showing 3 positive and -1 negative...I would want only one distinct record for positive and for cancelled&lt;/P&gt;</description>
      <pubDate>Wed, 15 May 2024 11:15:57 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Matrix-display-1-or-1-values-based-on-a-text-field/m-p/3920421#M152596</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2024-05-15T11:15:57Z</dc:date>
    </item>
    <item>
      <title>Re: Matrix - display 1 or -1 values based on a text field</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Matrix-display-1-or-1-values-based-on-a-text-field/m-p/3920660#M152601</link>
      <description>&lt;P&gt;I belive it should work when you have created a calculated column. Could you provide your Sample PBIX file by hiding all the sensitive Data&lt;/P&gt;</description>
      <pubDate>Wed, 15 May 2024 12:19:25 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Matrix-display-1-or-1-values-based-on-a-text-field/m-p/3920660#M152601</guid>
      <dc:creator>Learner27</dc:creator>
      <dc:date>2024-05-15T12:19:25Z</dc:date>
    </item>
    <item>
      <title>Re: Matrix - display 1 or -1 values based on a text field</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Matrix-display-1-or-1-values-based-on-a-text-field/m-p/3923172#M152672</link>
      <description>&lt;P&gt;&lt;FONT&gt;Hi&amp;nbsp;Anonymous&lt;/a&gt;&lt;/FONT&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks for the reply from &lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="583663" data-lia-user-login="Learner27" class="lia-mention lia-mention-user"&gt;Learner27&lt;/a&gt;&amp;nbsp;, please allow me to provide another insight:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;My sample:&lt;/P&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If you don't necessarily want to use a calculated column, try creating the following measure:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;Measure = IF(MAX([cancelled]) = BLANK(), CALCULATE(DISTINCTCOUNT('Table'[account]), ALLEXCEPT('Table', 'Table'[account])), -1)&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Output:&lt;/P&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If this sample data is structurally different from the one you are using, please do not hesitate to mention it and I will modify it.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Best Regards,&lt;BR /&gt;Yulia Xu&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If this post &lt;EM&gt;&lt;STRONG&gt;helps&lt;/STRONG&gt;&lt;/EM&gt;, then please consider &lt;EM&gt;&lt;STRONG&gt;Accept it as the solution&lt;/STRONG&gt;&lt;/EM&gt; to help the other members find it more quickly.&lt;/P&gt;</description>
      <pubDate>Thu, 16 May 2024 09:01:55 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Matrix-display-1-or-1-values-based-on-a-text-field/m-p/3923172#M152672</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2024-05-16T09:01:55Z</dc:date>
    </item>
  </channel>
</rss>

