<?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: A Measure that depends upon the result of another measure in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/A-Measure-that-depends-upon-the-result-of-another-measure/m-p/1403034#M25849</link>
    <description>&lt;P&gt;Just a tweak and 2nd measure&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="30852" data-lia-user-login="jader3rd" class="lia-mention lia-mention-user"&gt;jader3rd&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="cpp"&gt;UnInteresting Count = 
VAR varInterstingCount =
COUNTX(
    FILTER(
        'Table',
        'Table'[Reason] &amp;lt;&amp;gt; "Interesting"
    ),
    'Table'[Reason]
)
RETURN
COALESCE(varInterstingCount, 0)&lt;/LI-CODE&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Wed, 30 Sep 2020 00:09:19 GMT</pubDate>
    <dc:creator>edhans</dc:creator>
    <dc:date>2020-09-30T00:09:19Z</dc:date>
    <item>
      <title>A Measure that depends upon the result of another measure</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/A-Measure-that-depends-upon-the-result-of-another-measure/m-p/1402954#M25846</link>
      <description>&lt;P&gt;I have rows where certain values are interesting, and I want to split the data into HasInteresting with counts for true or false. The trick is that it's not if the row is interesting, but if any row in a certain grouping has an interesting row.&lt;/P&gt;&lt;P&gt;So if I have something like the below:&lt;/P&gt;&lt;TABLE border="1"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;ObjectName&lt;/TD&gt;&lt;TD&gt;Series&lt;/TD&gt;&lt;TD&gt;Reason&lt;/TD&gt;&lt;TD&gt;Duration&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;ObjA&lt;/TD&gt;&lt;TD&gt;X&lt;/TD&gt;&lt;TD&gt;Mild&lt;/TD&gt;&lt;TD&gt;12&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;ObjA&lt;/TD&gt;&lt;TD&gt;X&lt;/TD&gt;&lt;TD&gt;Interesting&lt;/TD&gt;&lt;TD&gt;454&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;ObjB&lt;/TD&gt;&lt;TD&gt;Y&lt;/TD&gt;&lt;TD&gt;Mediocre&lt;/TD&gt;&lt;TD&gt;12&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;ObjB&lt;/TD&gt;&lt;TD&gt;Y&lt;/TD&gt;&lt;TD&gt;Mild&lt;/TD&gt;&lt;TD&gt;32&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;ObjC&lt;/TD&gt;&lt;TD&gt;X&lt;/TD&gt;&lt;TD&gt;Mild&lt;/TD&gt;&lt;TD&gt;87&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;ObjC&lt;/TD&gt;&lt;TD&gt;X&lt;/TD&gt;&lt;TD&gt;Boring&lt;/TD&gt;&lt;TD&gt;37&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;I've added a calculated column of IsInteresting = IF([Reason] = "Interesting", 1, 0), and then a measure of HasInteresting = SUM([IsInteresting]) &amp;gt; 0. Which generates the following correct result.&lt;/P&gt;&lt;TABLE border="1"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;ObjectName&lt;/TD&gt;&lt;TD&gt;HasInteresting&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;ObjA&lt;/TD&gt;&lt;TD&gt;True&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;ObjB&lt;/TD&gt;&lt;TD&gt;False&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;ObjC&lt;/TD&gt;&lt;TD&gt;False&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;But what I want to know is "How many ObjectName's have an HasInteresting of True, and how many have False by Series".&lt;/P&gt;&lt;P&gt;It would look something like&lt;/P&gt;&lt;TABLE border="1"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;Series&lt;/TD&gt;&lt;TD&gt;HasInterestingTrue&lt;/TD&gt;&lt;TD&gt;HasInterestingFalse&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;X&lt;/TD&gt;&lt;TD&gt;1&lt;/TD&gt;&lt;TD&gt;1&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;Y&lt;/TD&gt;&lt;TD&gt;0&lt;/TD&gt;&lt;TD&gt;1&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I tried doing something with COUNTROWS, but that returned results from the original rows, not from the middle table.&lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 22:52:10 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/A-Measure-that-depends-upon-the-result-of-another-measure/m-p/1402954#M25846</guid>
      <dc:creator>jader3rd</dc:creator>
      <dc:date>2020-09-29T22:52:10Z</dc:date>
    </item>
    <item>
      <title>Re: A Measure that depends upon the result of another measure</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/A-Measure-that-depends-upon-the-result-of-another-measure/m-p/1403008#M25847</link>
      <description>&lt;P&gt;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="30852" data-lia-user-login="jader3rd" class="lia-mention lia-mention-user"&gt;jader3rd&lt;/a&gt;&amp;nbsp;I would try to avoid the intermedary tables and calculated columns if possible. Try something like this, which is a single measure:&lt;/P&gt;
&lt;LI-CODE lang="cpp"&gt;Interesting Count = 
VAR varInterstingCount =
COUNTX(
    FILTER(
        'Table',
        'Table'[Reason] = "Interesting"
    ),
    'Table'[Reason]
)
RETURN
COALESCE(varInterstingCount, 0)&lt;/LI-CODE&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;In general, try to avoid calculated columns. There are times to use them, but it is rare. Getting data out of the source system, creating columns in Power Query, or DAX Measures are usually preferred to calculated columns. See these references:&lt;BR /&gt;&lt;A href="https://exceleratorbi.com.au/calculated-columns-vs-measures-dax/" rel="noopener" target="_blank"&gt;Calculated Columns vs Measures in DAX&lt;/A&gt;&lt;BR /&gt;&lt;A href="https://www.sqlbi.com/articles/calculated-columns-and-measures-in-dax/" rel="noopener" target="_blank"&gt;Calculated Columns and Measures in DAX&lt;/A&gt;&lt;BR /&gt;&lt;A href="https://www.sqlbi.com/articles/storage-differences-between-calculated-columns-and-calculated-tables//" rel="noopener" target="_blank"&gt;Storage differences between calculated columns and calculated tables&lt;/A&gt;&lt;BR /&gt;&lt;A href="https://www.youtube.com/watch?v=ePPi1LLX0sA" rel="noopener" target="_blank"&gt;SQLBI Video on Measures vs Calculated Columns&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;
&lt;P&gt;Does that help?&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 23:41:59 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/A-Measure-that-depends-upon-the-result-of-another-measure/m-p/1403008#M25847</guid>
      <dc:creator>edhans</dc:creator>
      <dc:date>2020-09-29T23:41:59Z</dc:date>
    </item>
    <item>
      <title>Re: A Measure that depends upon the result of another measure</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/A-Measure-that-depends-upon-the-result-of-another-measure/m-p/1403026#M25848</link>
      <description>&lt;P&gt;That gets me the interesting count, but I also need the uninteresting. I am trying to do a comparison of how many Objects have any rows which are interesting, vs how many do not have any interesting rows.&lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 23:55:52 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/A-Measure-that-depends-upon-the-result-of-another-measure/m-p/1403026#M25848</guid>
      <dc:creator>jader3rd</dc:creator>
      <dc:date>2020-09-29T23:55:52Z</dc:date>
    </item>
    <item>
      <title>Re: A Measure that depends upon the result of another measure</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/A-Measure-that-depends-upon-the-result-of-another-measure/m-p/1403034#M25849</link>
      <description>&lt;P&gt;Just a tweak and 2nd measure&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="30852" data-lia-user-login="jader3rd" class="lia-mention lia-mention-user"&gt;jader3rd&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="cpp"&gt;UnInteresting Count = 
VAR varInterstingCount =
COUNTX(
    FILTER(
        'Table',
        'Table'[Reason] &amp;lt;&amp;gt; "Interesting"
    ),
    'Table'[Reason]
)
RETURN
COALESCE(varInterstingCount, 0)&lt;/LI-CODE&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 30 Sep 2020 00:09:19 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/A-Measure-that-depends-upon-the-result-of-another-measure/m-p/1403034#M25849</guid>
      <dc:creator>edhans</dc:creator>
      <dc:date>2020-09-30T00:09:19Z</dc:date>
    </item>
    <item>
      <title>Re: A Measure that depends upon the result of another measure</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/A-Measure-that-depends-upon-the-result-of-another-measure/m-p/1403040#M25850</link>
      <description>&lt;P&gt;Wow... my spelling is horrible....&amp;nbsp;&lt;span class="lia-unicode-emoji" title=":face_with_tears_of_joy:"&gt;😂&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 30 Sep 2020 00:12:50 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/A-Measure-that-depends-upon-the-result-of-another-measure/m-p/1403040#M25850</guid>
      <dc:creator>edhans</dc:creator>
      <dc:date>2020-09-30T00:12:50Z</dc:date>
    </item>
    <item>
      <title>Re: A Measure that depends upon the result of another measure</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/A-Measure-that-depends-upon-the-result-of-another-measure/m-p/1403041#M25851</link>
      <description>&lt;P&gt;That's still the Count of Rows, not the Count of ObjectNames which do contain an interesting Reason, and those which don't at all. The total sum in the final table should be 3, because there are 3 ObjectNames.&lt;/P&gt;</description>
      <pubDate>Wed, 30 Sep 2020 00:16:54 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/A-Measure-that-depends-upon-the-result-of-another-measure/m-p/1403041#M25851</guid>
      <dc:creator>jader3rd</dc:creator>
      <dc:date>2020-09-30T00:16:54Z</dc:date>
    </item>
    <item>
      <title>Re: A Measure that depends upon the result of another measure</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/A-Measure-that-depends-upon-the-result-of-another-measure/m-p/1403426#M25857</link>
      <description>&lt;P&gt;Ok&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="30852" data-lia-user-login="jader3rd" class="lia-mention lia-mention-user"&gt;jader3rd&lt;/a&gt;&amp;nbsp;- I didn't understand fully the original request. So this is a bit longer,but still two measures.&lt;/P&gt;
&lt;LI-CODE lang="cpp"&gt;Interesting Count = 
COUNTX(
    FILTER(
        ADDCOLUMNS(
            SUMMARIZE(
                'Table',
                'Table'[ObjectName],
                'Table'[Series]
            ),
            "Reasons",
                CONTAINSSTRING(
                    CALCULATE(
                        CONCATENATEX(
                            'Table',
                            'Table'[Reason],
                            ", "
                        )
                    ),
                    "Interesting"
                ) * 1
        ),
        [Reasons] = 1
    ),
    [Reasons]
)&lt;/LI-CODE&gt;
&lt;P&gt;and&lt;/P&gt;
&lt;LI-CODE lang="cpp"&gt;UnInteresting Count = 
COUNTX(
    FILTER(
        ADDCOLUMNS(
            SUMMARIZE(
                'Table',
                'Table'[ObjectName],
                'Table'[Series]
            ),
            "Reasons",
                CONTAINSSTRING(
                    CALCULATE(
                        CONCATENATEX(
                            'Table',
                            'Table'[Reason],
                            ", "
                        )
                    ),
                    "Interesting"
                ) * 1
        ),
        [Reasons] = 0
    ),
    [Reasons]
)&lt;/LI-CODE&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;It does this by building a virtual table first that looks like this:&lt;/P&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;which comes from this - you can see this in DAX Studio, or you could create a new calculated table with this code to see it:&lt;/P&gt;
&lt;LI-CODE lang="cpp"&gt;ADDCOLUMNS(
    SUMMARIZE(
        'Table',
        'Table'[ObjectName],
        'Table'[Series]
    ),
    "Reasons",
        CONTAINSSTRING(
            CALCULATE(
                CONCATENATEX(
                    'Table',
                    'Table'[Reason],
                    ", "
                )
            ),
            "Interesting"
        )
)&lt;/LI-CODE&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;then the rest just converts the true/false to 1/0, then it counts those.&lt;BR /&gt;&lt;BR /&gt;I do wonder if&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;or&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="31" data-lia-user-login="TomMartens" class="lia-mention lia-mention-user"&gt;TomMartens&lt;/a&gt;&amp;nbsp;could shorten this up a bit though.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 30 Sep 2020 03:49:38 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/A-Measure-that-depends-upon-the-result-of-another-measure/m-p/1403426#M25857</guid>
      <dc:creator>edhans</dc:creator>
      <dc:date>2020-09-30T03:49:38Z</dc:date>
    </item>
    <item>
      <title>Re: A Measure that depends upon the result of another measure</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/A-Measure-that-depends-upon-the-result-of-another-measure/m-p/1404680#M25898</link>
      <description>&lt;P&gt;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="30852" data-lia-user-login="jader3rd" class="lia-mention lia-mention-user"&gt;jader3rd&lt;/a&gt;&amp;nbsp; Try this:&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;HasInterestingTrue = 
CALCULATE (
    COUNTROWS ( DISTINCT ( Jader[ObjectName] ) ),
    Jader[Reason] = "Interesting"
) + 0
&lt;/LI-CODE&gt;&lt;LI-CODE lang="markup"&gt;HasInterestingFalse = 
VAR ObjectThatHasInteresting =
    CALCULATETABLE ( DISTINCT ( Jader[ObjectName] ), Jader[Reason] = "Interesting" )
VAR Result =
    CALCULATE (
        COUNTROWS ( DISTINCT ( Jader[ObjectName] ) ),
        Jader[Reason] &amp;lt;&amp;gt; "Interesting",
        NOT Jader[ObjectName] IN ObjectThatHasInteresting
    )
RETURN
    Result
&lt;/LI-CODE&gt;
&lt;P&gt;&lt;img /&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 30 Sep 2020 11:56:18 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/A-Measure-that-depends-upon-the-result-of-another-measure/m-p/1404680#M25898</guid>
      <dc:creator>AntrikshSharma</dc:creator>
      <dc:date>2020-09-30T11:56:18Z</dc:date>
    </item>
    <item>
      <title>Re: A Measure that depends upon the result of another measure</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/A-Measure-that-depends-upon-the-result-of-another-measure/m-p/1405070#M25913</link>
      <description>&lt;P&gt;Different way of thinking&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="236628" data-lia-user-login="AntrikshSharma" class="lia-mention lia-mention-user"&gt;AntrikshSharma&lt;/a&gt;&amp;nbsp;&lt;span class="lia-unicode-emoji" title=":thumbs_up:"&gt;👍&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;My approach was to calculate each one the same way and just look at the results of the calculated table. But the hard part was getting any object name that had an "interesting" in it and excluding it for all same object names that didn't. You just set that to a variable, then excluded it from your final results.&lt;/P&gt;</description>
      <pubDate>Wed, 30 Sep 2020 14:46:34 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/A-Measure-that-depends-upon-the-result-of-another-measure/m-p/1405070#M25913</guid>
      <dc:creator>edhans</dc:creator>
      <dc:date>2020-09-30T14:46:34Z</dc:date>
    </item>
    <item>
      <title>Re: A Measure that depends upon the result of another measure</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/A-Measure-that-depends-upon-the-result-of-another-measure/m-p/1405451#M25929</link>
      <description>&lt;P&gt;Thanks for your trial and error with this&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="24715" data-lia-user-login="edhans" class="lia-mention lia-mention-user"&gt;edhans&lt;/a&gt;. It means a lot to me.&lt;/P&gt;</description>
      <pubDate>Wed, 30 Sep 2020 17:09:25 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/A-Measure-that-depends-upon-the-result-of-another-measure/m-p/1405451#M25929</guid>
      <dc:creator>jader3rd</dc:creator>
      <dc:date>2020-09-30T17:09:25Z</dc:date>
    </item>
    <item>
      <title>Re: A Measure that depends upon the result of another measure</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/A-Measure-that-depends-upon-the-result-of-another-measure/m-p/1405457#M25930</link>
      <description>&lt;P&gt;This works. But now that I have your attention, I would like your thoughts on where my thinking has gone wrong with something I was trying a few hours ago. I thought that I could create a Measure using GROUPBY and make use of that.&lt;/P&gt;&lt;LI-CODE lang="csharp"&gt;Measure = GROUPBY(jader, jader[ObjectName], "HasInteresting", MAXX(CURRENTGROUP(), IF(jader[Reason], 1, 0)))&lt;/LI-CODE&gt;&lt;P&gt;The above errors out with "The expression refers to multiple columns. Multiple columns cannot be converted to a scalar value". What am I not understanding about GROUPBY?&lt;/P&gt;</description>
      <pubDate>Wed, 30 Sep 2020 17:13:50 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/A-Measure-that-depends-upon-the-result-of-another-measure/m-p/1405457#M25930</guid>
      <dc:creator>jader3rd</dc:creator>
      <dc:date>2020-09-30T17:13:50Z</dc:date>
    </item>
    <item>
      <title>Re: A Measure that depends upon the result of another measure</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/A-Measure-that-depends-upon-the-result-of-another-measure/m-p/1405498#M25931</link>
      <description>&lt;P&gt;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="30852" data-lia-user-login="jader3rd" class="lia-mention lia-mention-user"&gt;jader3rd&lt;/a&gt;&amp;nbsp; GROUPBY is a table function, your measure returns the below table, and implicitly DAX can only convert 1 row and 1 column table into a scalar value. Hence your measure throws an error.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Also had to do a comparision inside IF otherwise it won't work.&lt;/P&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 30 Sep 2020 17:35:36 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/A-Measure-that-depends-upon-the-result-of-another-measure/m-p/1405498#M25931</guid>
      <dc:creator>AntrikshSharma</dc:creator>
      <dc:date>2020-09-30T17:35:36Z</dc:date>
    </item>
    <item>
      <title>Re: A Measure that depends upon the result of another measure</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/A-Measure-that-depends-upon-the-result-of-another-measure/m-p/1405516#M25932</link>
      <description>&lt;P&gt;Okay. I normally figure out the formulas by solving an inner part and then wrapping it in the next level. That approach apparently doesn't work with GROUP BY.&lt;/P&gt;&lt;P&gt;What would I wrap the GROUP BY in to make the Measure?&lt;/P&gt;</description>
      <pubDate>Wed, 30 Sep 2020 17:48:53 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/A-Measure-that-depends-upon-the-result-of-another-measure/m-p/1405516#M25932</guid>
      <dc:creator>jader3rd</dc:creator>
      <dc:date>2020-09-30T17:48:53Z</dc:date>
    </item>
    <item>
      <title>Re: A Measure that depends upon the result of another measure</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/A-Measure-that-depends-upon-the-result-of-another-measure/m-p/1405563#M25934</link>
      <description>&lt;P&gt;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="30852" data-lia-user-login="jader3rd" class="lia-mention lia-mention-user"&gt;jader3rd&lt;/a&gt;&amp;nbsp;That's where things always go wrong, I have stopped thinking of DAX as excel formulas or any other programming language, because you have to think holistically and not just from inside out.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;GROUPBY is useful when you have created temporary columns on the fly and you want to summarize the result by those columns but aren't able to do so because they do not carry the data lineage of a column of the model. CURRENTGROUP helps in accessing the current row context and then you can apply SUMX, COUNTX or any either iterator to get the result for the values created virtually.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;But here is how you can make your version work.&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;JaderM =
SUMX (
    GROUPBY (
        jader,
        jader[ObjectName],
        Jader[Reason],
        "HasInteresting", SUMX ( CURRENTGROUP (), IF ( jader[Reason] = "Interesting", 1, 0 ) )
    ),
    [HasInteresting]
)
&lt;/LI-CODE&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 30 Sep 2020 18:13:33 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/A-Measure-that-depends-upon-the-result-of-another-measure/m-p/1405563#M25934</guid>
      <dc:creator>AntrikshSharma</dc:creator>
      <dc:date>2020-09-30T18:13:33Z</dc:date>
    </item>
    <item>
      <title>Re: A Measure that depends upon the result of another measure</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/A-Measure-that-depends-upon-the-result-of-another-measure/m-p/1405620#M25935</link>
      <description>&lt;P&gt;That does get me the count for HasInteresting, but it's not working for the count of objects names with no interesting reasons.&lt;/P&gt;&lt;P&gt;I tried&lt;/P&gt;&lt;LI-CODE lang="csharp"&gt;Measure2 = COUNTROWS( FILTER(GROUPBY (jader, jader[ObjectName], jader[Reason], "HasInteresting", MAXX( CURRENTGROUP(), IF (jader[Reason] = "Interesting", 1, 0))), [HasInteresting] = 0))&lt;/LI-CODE&gt;&lt;P&gt;But that gives the count of the underlying rows that doesn't have interesting. Which boggles my mind. The GROUPBY should group on object name and return a 3 row table to the Filter. The Filter statement should then filter out the single row with HasInteresting = 1, and return two rows. The COUNTROWS should then count the two remaining rows. Obviously I have something backwards.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 30 Sep 2020 18:46:27 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/A-Measure-that-depends-upon-the-result-of-another-measure/m-p/1405620#M25935</guid>
      <dc:creator>jader3rd</dc:creator>
      <dc:date>2020-09-30T18:46:27Z</dc:date>
    </item>
    <item>
      <title>Re: A Measure that depends upon the result of another measure</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/A-Measure-that-depends-upon-the-result-of-another-measure/m-p/1405632#M25936</link>
      <description>&lt;P&gt;You can try to debug your measure step by step in a table and you can see the rows returned by GROUPBY to FILTER&lt;/P&gt;</description>
      <pubDate>Wed, 30 Sep 2020 19:00:22 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/A-Measure-that-depends-upon-the-result-of-another-measure/m-p/1405632#M25936</guid>
      <dc:creator>AntrikshSharma</dc:creator>
      <dc:date>2020-09-30T19:00:22Z</dc:date>
    </item>
    <item>
      <title>Re: A Measure that depends upon the result of another measure</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/A-Measure-that-depends-upon-the-result-of-another-measure/m-p/1405731#M25940</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="30852" data-lia-user-login="jader3rd" class="lia-mention lia-mention-user"&gt;jader3rd&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;Thanks for your trial and error with this&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="24715" data-lia-user-login="edhans" class="lia-mention lia-mention-user"&gt;edhans&lt;/a&gt;. It means a lot to me.&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;Glad to help&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="30852" data-lia-user-login="jader3rd" class="lia-mention lia-mention-user"&gt;jader3rd&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The approach of&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="236628" data-lia-user-login="AntrikshSharma" class="lia-mention lia-mention-user"&gt;AntrikshSharma&lt;/a&gt;&amp;nbsp;is really common sense from the standpoint of build result a, then result b and exclude result a from b.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;But I was so far down the path mentally of building the tables in my original solution, I didn't see the forest for the trees.&amp;nbsp;&lt;span class="lia-unicode-emoji" title=":beaming_face_with_smiling_eyes:"&gt;😁&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;But I did get a blog post out of it. Found out some weird behavior using NOT as an operator and function, which it can do both, so all is not lost.&lt;BR /&gt;&lt;BR /&gt;Kudos appreciated, and glad you have a working solution!&lt;/P&gt;</description>
      <pubDate>Wed, 30 Sep 2020 19:48:32 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/A-Measure-that-depends-upon-the-result-of-another-measure/m-p/1405731#M25940</guid>
      <dc:creator>edhans</dc:creator>
      <dc:date>2020-09-30T19:48:32Z</dc:date>
    </item>
    <item>
      <title>Re: A Measure that depends upon the result of another measure</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/A-Measure-that-depends-upon-the-result-of-another-measure/m-p/1405856#M25944</link>
      <description>&lt;P&gt;I see what I did wrong now. I put&amp;nbsp;&lt;SPAN&gt;jader[Reason] in the GROUP BY, even though I shouldn't have. Now it all makes sense.&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 30 Sep 2020 21:08:04 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/A-Measure-that-depends-upon-the-result-of-another-measure/m-p/1405856#M25944</guid>
      <dc:creator>jader3rd</dc:creator>
      <dc:date>2020-09-30T21:08:04Z</dc:date>
    </item>
  </channel>
</rss>

