<?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: Return an array of unique values in a measure/variable as a filter for further calculations in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Return-an-array-of-unique-values-in-a-measure-variable-as-a/m-p/2894267#M94032</link>
    <description>&lt;P&gt;You can use VALUES(&amp;lt;TableNameOrColumnName&amp;gt;) for array of unique values in a column&lt;/P&gt;</description>
    <pubDate>Wed, 09 Nov 2022 05:04:36 GMT</pubDate>
    <dc:creator>kunal15sep</dc:creator>
    <dc:date>2022-11-09T05:04:36Z</dc:date>
    <item>
      <title>Return an array of unique values in a measure/variable as a filter for further calculations</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Return-an-array-of-unique-values-in-a-measure-variable-as-a/m-p/2894252#M94030</link>
      <description>&lt;P&gt;I wish to return an array or a list of unique "PersonIDs" in a measure/variable within a measure.&lt;BR /&gt;&lt;BR /&gt;And then use it as a filter for another measure/variable to display the results for only those personID's who were there in previous case.&lt;/P&gt;</description>
      <pubDate>Wed, 09 Nov 2022 04:52:02 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Return-an-array-of-unique-values-in-a-measure-variable-as-a/m-p/2894252#M94030</guid>
      <dc:creator>ssingh_leecare</dc:creator>
      <dc:date>2022-11-09T04:52:02Z</dc:date>
    </item>
    <item>
      <title>Re: Return an array of unique values in a measure/variable as a filter for further calculations</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Return-an-array-of-unique-values-in-a-measure-variable-as-a/m-p/2894267#M94032</link>
      <description>&lt;P&gt;You can use VALUES(&amp;lt;TableNameOrColumnName&amp;gt;) for array of unique values in a column&lt;/P&gt;</description>
      <pubDate>Wed, 09 Nov 2022 05:04:36 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Return-an-array-of-unique-values-in-a-measure-variable-as-a/m-p/2894267#M94032</guid>
      <dc:creator>kunal15sep</dc:creator>
      <dc:date>2022-11-09T05:04:36Z</dc:date>
    </item>
    <item>
      <title>Re: Return an array of unique values in a measure/variable as a filter for further calculations</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Return-an-array-of-unique-values-in-a-measure-variable-as-a/m-p/2894270#M94033</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="469093" data-lia-user-login="kunal15sep" class="lia-mention lia-mention-user"&gt;kunal15sep&lt;/a&gt;&amp;nbsp;&lt;BR /&gt;And how should I use that as a filter in the next statement, something like&lt;BR /&gt;var A = values(personID)&lt;BR /&gt;filter(personIDs IN A)&lt;/P&gt;</description>
      <pubDate>Wed, 09 Nov 2022 05:07:56 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Return-an-array-of-unique-values-in-a-measure-variable-as-a/m-p/2894270#M94033</guid>
      <dc:creator>ssingh_leecare</dc:creator>
      <dc:date>2022-11-09T05:07:56Z</dc:date>
    </item>
    <item>
      <title>Re: Return an array of unique values in a measure/variable as a filter for further calculations</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Return-an-array-of-unique-values-in-a-measure-variable-as-a/m-p/2894275#M94035</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;I do not know how your datamodel looks like, but I tried to create a sample pbix file like below.&lt;/P&gt;
&lt;P&gt;Please check the below picture and the attached pbix file.&lt;/P&gt;
&lt;P&gt;I hope the below sample can provide some ideas on how to create a solution for your datamodel.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;September 2022 qty &amp;gt; 15 IDs total qty: =
VAR _condition =
    FILTER (
        ADDCOLUMNS (
            ALL ( PersonID[PersonID] ),
            "@sepQTY",
                CALCULATE (
                    SUM ( Sales[Quantity] ),
                    EOMONTH ( Sales[Date], 0 ) = DATE ( 2022, 9, 30 )
                )
        ),
        [@sepQTY] &amp;gt; 15
    )
VAR _list =
    SUMMARIZE ( _condition, PersonID[PersonID] )
RETURN
    CALCULATE (
        SUM ( Sales[Quantity] ),
        KEEPFILTERS ( PersonID[PersonID] IN _list )
    )
&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 09 Nov 2022 05:10:31 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Return-an-array-of-unique-values-in-a-measure-variable-as-a/m-p/2894275#M94035</guid>
      <dc:creator>Jihwan_Kim</dc:creator>
      <dc:date>2022-11-09T05:10:31Z</dc:date>
    </item>
    <item>
      <title>Re: Return an array of unique values in a measure/variable as a filter for further calculations</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Return-an-array-of-unique-values-in-a-measure-variable-as-a/m-p/2894291#M94036</link>
      <description>&lt;P&gt;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="363242" data-lia-user-login="ssingh_leecare" class="lia-mention lia-mention-user"&gt;ssingh_leecare&lt;/a&gt;&amp;nbsp;, If what I understand to be your requirement, you may consider using calculated column to LOOKUPVALUE and return 1 or 0 comparing from the previous case table. Then filtering the table view to get aggregated measures.&lt;/P&gt;</description>
      <pubDate>Wed, 09 Nov 2022 05:16:56 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Return-an-array-of-unique-values-in-a-measure-variable-as-a/m-p/2894291#M94036</guid>
      <dc:creator>kunal15sep</dc:creator>
      <dc:date>2022-11-09T05:16:56Z</dc:date>
    </item>
    <item>
      <title>Re: Return an array of unique values in a measure/variable as a filter for further calculations</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Return-an-array-of-unique-values-in-a-measure-variable-as-a/m-p/2894330#M94040</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="469093" data-lia-user-login="kunal15sep" class="lia-mention lia-mention-user"&gt;kunal15sep&lt;/a&gt;&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="291628" data-lia-user-login="Jihwan_Kim" class="lia-mention lia-mention-user"&gt;Jihwan_Kim&lt;/a&gt;&amp;nbsp;&lt;BR /&gt;Thank you for your responses. I will explain the problem I have and what I am trying to achieve. These are the tables and connections I have right now.&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;FirstFormSaves has first saves for different forms for every personID, with the dates the forms were saved. So, for every personID, there's only one Form save of a certain type.&amp;nbsp;&lt;BR /&gt;This is connected to date table.&lt;BR /&gt;&lt;BR /&gt;Person has all the personIDs.&lt;BR /&gt;&lt;BR /&gt;Status is the table with personIDs, their status and the dates.&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;I am using a timeline slicer. Assuming start date is A and End Date is B, I wish to return:&lt;BR /&gt;&lt;BR /&gt;Get those personIDs which had status "XYZ" between A and B from table Status (Or Person since it is a 2-way relation).&lt;BR /&gt;Once we have these personIDs, get the total of all forms saved till B (Ignore start date A) only for those personIDs who we got from the statement above.&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;The personIDs we need have to be with status XYZ only between A and B. Forms saved should be everything till B, for only these personIDs.&lt;BR /&gt;&lt;BR /&gt;I hope this clears the doubts, let me know if you need anything else.&lt;BR /&gt;Thanks in advance!&lt;/P&gt;</description>
      <pubDate>Wed, 09 Nov 2022 05:32:13 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Return-an-array-of-unique-values-in-a-measure-variable-as-a/m-p/2894330#M94040</guid>
      <dc:creator>ssingh_leecare</dc:creator>
      <dc:date>2022-11-09T05:32:13Z</dc:date>
    </item>
    <item>
      <title>Re: Return an array of unique values in a measure/variable as a filter for further calculations</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Return-an-array-of-unique-values-in-a-measure-variable-as-a/m-p/2894363#M94042</link>
      <description>&lt;P&gt;&lt;A href="https://community.powerbi.com/t5/Desktop/Return-an-array-through-a-measure-and-then-use-that-as-a-filter/m-p/2882095#M991810" target="_blank"&gt;Re: Return an array through a measure, and then us... - Microsoft Power BI Community&lt;/A&gt;&lt;BR /&gt;This was also posted by me and&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="148838" data-lia-user-login="amitchandak" class="lia-mention lia-mention-user"&gt;amitchandak&lt;/a&gt;&amp;nbsp;shared some insights, which may help.&lt;BR /&gt;&lt;BR /&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="148838" data-lia-user-login="amitchandak" class="lia-mention lia-mention-user"&gt;amitchandak&lt;/a&gt;, this is a detailed explanation of what I am after.&lt;BR /&gt;&lt;BR /&gt;Thanks in advance!&lt;/P&gt;</description>
      <pubDate>Wed, 09 Nov 2022 05:42:53 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Return-an-array-of-unique-values-in-a-measure-variable-as-a/m-p/2894363#M94042</guid>
      <dc:creator>ssingh_leecare</dc:creator>
      <dc:date>2022-11-09T05:42:53Z</dc:date>
    </item>
    <item>
      <title>Re: Return an array of unique values in a measure/variable as a filter for further calculations</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Return-an-array-of-unique-values-in-a-measure-variable-as-a/m-p/2894376#M94045</link>
      <description>&lt;P&gt;In response to a calculated column, it has to be dynamic and change with the selection on date slicer, which won't be possible if I make a calculated column.&lt;/P&gt;</description>
      <pubDate>Wed, 09 Nov 2022 05:48:25 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Return-an-array-of-unique-values-in-a-measure-variable-as-a/m-p/2894376#M94045</guid>
      <dc:creator>ssingh_leecare</dc:creator>
      <dc:date>2022-11-09T05:48:25Z</dc:date>
    </item>
  </channel>
</rss>

