<?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: Help with DAX measure for two dates in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Help-with-DAX-measure-for-two-dates/m-p/2325978#M58238</link>
    <description>&lt;P&gt;Then maybe something like this will work for the variables:&lt;/P&gt;
&lt;LI-CODE lang="php"&gt;VAR _MaxEnter =
    CALCULATE (
        MAX ( Table1[Entry Date] ),
        ALLEXCEPT ( Table1, Table1[Customer], Table1[FiscalYear] )
    )
VAR _MaxExit =
    CALCULATE (
        MAX ( Table1[Exit Date] ),
        ALLEXCEPT ( Table1, Table1[Customer], Table1[FiscalYear] )
    )&lt;/LI-CODE&gt;
&lt;P&gt;It's hard to say for sure though without seeing your actual data.&lt;/P&gt;</description>
    <pubDate>Tue, 08 Feb 2022 15:40:21 GMT</pubDate>
    <dc:creator>AlexisOlson</dc:creator>
    <dc:date>2022-02-08T15:40:21Z</dc:date>
    <item>
      <title>Help with DAX measure for two dates</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Help-with-DAX-measure-for-two-dates/m-p/2323901#M58116</link>
      <description>&lt;P&gt;I have two date columns in my dataset, one entry and one exit. Customers can have multiple entries and exits in the same fiscal year. I need to categorize them and it seems like a measure or calculated column would be best but I'm struggling with the DAX for it. Basically, if their max entry date is later than their max exit date within the same fiscal year I would classify them as a 1 or as reactivated, but if their max exit date is later than their max entry date within the same fiscal year I would classify them as a 0 or as withdrawn.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 07 Feb 2022 19:29:25 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Help-with-DAX-measure-for-two-dates/m-p/2323901#M58116</guid>
      <dc:creator>CoordAnalytics</dc:creator>
      <dc:date>2022-02-07T19:29:25Z</dc:date>
    </item>
    <item>
      <title>Re: Help with DAX measure for two dates</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Help-with-DAX-measure-for-two-dates/m-p/2324020#M58123</link>
      <description>&lt;P&gt;I don't know how your date logic is set up (like whether you have a date dimension table or not), so ignoring the year aspect for now, you could write something like this:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="php"&gt;VAR _MaxEnter =
    CALCULATE ( MAX ( Table1[Entry] ), ALLEXCEPT ( Table1, Table1[Customer] ) )
VAR _MaxExit =
    CALCULATE ( MAX ( Table1[Entry] ), ALLEXCEPT ( Table1, Table1[Customer] ) )
RETURN
    SWITCH (
        TRUE (),
        ISBLANK ( _MaxExit ) &amp;amp;&amp;amp; ISBLANK ( _MaxEnter ), 0,
        ISBLANK ( _MaxExit ), 1,
        ISBLANK ( _MaxEnter ), 0,
        _MaxExit &amp;gt; _MaxEnter, 0,
        _MaxExit &amp;lt;= _MaxEnter, 1
    )&lt;/LI-CODE&gt;
&lt;P&gt;Please double-check my logic for how you want the various cases to work.&lt;/P&gt;</description>
      <pubDate>Mon, 07 Feb 2022 21:53:39 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Help-with-DAX-measure-for-two-dates/m-p/2324020#M58123</guid>
      <dc:creator>AlexisOlson</dc:creator>
      <dc:date>2022-02-07T21:53:39Z</dc:date>
    </item>
    <item>
      <title>Re: Help with DAX measure for two dates</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Help-with-DAX-measure-for-two-dates/m-p/2324022#M58124</link>
      <description>&lt;P&gt;I have a date table that has an active relationship between the date and the entry date column and an inactive reltionship with the exit date. The entry/exit table also has a column for fiscal year since it runs outside of a calendar year.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 07 Feb 2022 22:00:15 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Help-with-DAX-measure-for-two-dates/m-p/2324022#M58124</guid>
      <dc:creator>CoordAnalytics</dc:creator>
      <dc:date>2022-02-07T22:00:15Z</dc:date>
    </item>
    <item>
      <title>Re: Help with DAX measure for two dates</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Help-with-DAX-measure-for-two-dates/m-p/2324040#M58126</link>
      <description>&lt;P&gt;Do you ever have rows where the entry and exit dates in that specific row are from different fiscal years? If so, which date does the fiscal year column correspond to?&lt;/P&gt;</description>
      <pubDate>Mon, 07 Feb 2022 22:08:36 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Help-with-DAX-measure-for-two-dates/m-p/2324040#M58126</guid>
      <dc:creator>AlexisOlson</dc:creator>
      <dc:date>2022-02-07T22:08:36Z</dc:date>
    </item>
    <item>
      <title>Re: Help with DAX measure for two dates</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Help-with-DAX-measure-for-two-dates/m-p/2324047#M58127</link>
      <description>&lt;P&gt;No, every row only contains dates for the corresponding fiscal year.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 07 Feb 2022 22:11:05 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Help-with-DAX-measure-for-two-dates/m-p/2324047#M58127</guid>
      <dc:creator>CoordAnalytics</dc:creator>
      <dc:date>2022-02-07T22:11:05Z</dc:date>
    </item>
    <item>
      <title>Re: Help with DAX measure for two dates</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Help-with-DAX-measure-for-two-dates/m-p/2325978#M58238</link>
      <description>&lt;P&gt;Then maybe something like this will work for the variables:&lt;/P&gt;
&lt;LI-CODE lang="php"&gt;VAR _MaxEnter =
    CALCULATE (
        MAX ( Table1[Entry Date] ),
        ALLEXCEPT ( Table1, Table1[Customer], Table1[FiscalYear] )
    )
VAR _MaxExit =
    CALCULATE (
        MAX ( Table1[Exit Date] ),
        ALLEXCEPT ( Table1, Table1[Customer], Table1[FiscalYear] )
    )&lt;/LI-CODE&gt;
&lt;P&gt;It's hard to say for sure though without seeing your actual data.&lt;/P&gt;</description>
      <pubDate>Tue, 08 Feb 2022 15:40:21 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Help-with-DAX-measure-for-two-dates/m-p/2325978#M58238</guid>
      <dc:creator>AlexisOlson</dc:creator>
      <dc:date>2022-02-08T15:40:21Z</dc:date>
    </item>
    <item>
      <title>Re: Help with DAX measure for two dates</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Help-with-DAX-measure-for-two-dates/m-p/2335621#M58830</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="294153" data-lia-user-login="CoordAnalytics" class="lia-mention lia-mention-user"&gt;CoordAnalytics&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Could you tell me if your problem has been &lt;STRONG&gt;solved&lt;/STRONG&gt; by &lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="39298" data-lia-user-login="AlexisOlson" class="lia-mention lia-mention-user"&gt;AlexisOlson&lt;/a&gt;&amp;nbsp;'s suggestion? If it is, kindly &lt;STRONG&gt;Accept it as the solution&lt;/STRONG&gt;. More people will benefit from it.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Or if you are still confused about it, please provide me with more details about your table and your problem or share me with your pbix file after &lt;STRONG&gt;removing sensitive data&lt;/STRONG&gt;.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&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"&gt; How to provide sample data in the Power BI Forum - Microsoft Power BI Community &lt;/A&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"&gt; How to Get Your Question Answered Quickly - Microsoft Power BI Community &lt;/A&gt;&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;Eyelyn Qin&lt;/P&gt;</description>
      <pubDate>Mon, 14 Feb 2022 02:15:01 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Help-with-DAX-measure-for-two-dates/m-p/2335621#M58830</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2022-02-14T02:15:01Z</dc:date>
    </item>
  </channel>
</rss>

