<?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 Text for past and Date for present and future in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Text-for-past-and-Date-for-present-and-future/m-p/3112276#M110009</link>
    <description>&lt;P&gt;Hi all!&lt;/P&gt;
&lt;P&gt;I have a column with a lot of dates. Now I would like to add a calculated column that displays "Past" if the Date if in the past. If the date is today or in the future, I would like to see the Date.&lt;/P&gt;
&lt;P&gt;How would you do that?&lt;/P&gt;</description>
    <pubDate>Sun, 05 Mar 2023 14:12:01 GMT</pubDate>
    <dc:creator>joshua1990</dc:creator>
    <dc:date>2023-03-05T14:12:01Z</dc:date>
    <item>
      <title>Text for past and Date for present and future</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Text-for-past-and-Date-for-present-and-future/m-p/3112276#M110009</link>
      <description>&lt;P&gt;Hi all!&lt;/P&gt;
&lt;P&gt;I have a column with a lot of dates. Now I would like to add a calculated column that displays "Past" if the Date if in the past. If the date is today or in the future, I would like to see the Date.&lt;/P&gt;
&lt;P&gt;How would you do that?&lt;/P&gt;</description>
      <pubDate>Sun, 05 Mar 2023 14:12:01 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Text-for-past-and-Date-for-present-and-future/m-p/3112276#M110009</guid>
      <dc:creator>joshua1990</dc:creator>
      <dc:date>2023-03-05T14:12:01Z</dc:date>
    </item>
    <item>
      <title>Re: Text for past and Date for present and future</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Text-for-past-and-Date-for-present-and-future/m-p/3112285#M110011</link>
      <description>&lt;P&gt;Hi,&lt;BR /&gt;&lt;BR /&gt;This should do the trick:&amp;nbsp;&lt;/P&gt;
&lt;DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;Past = &lt;/SPAN&gt;&lt;SPAN&gt;IF&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;[Date]&lt;/SPAN&gt;&lt;SPAN&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN&gt;TODAY&lt;/SPAN&gt;&lt;SPAN&gt;(),&lt;/SPAN&gt;&lt;SPAN&gt;"Past"&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;/SPAN&gt;&lt;SPAN&gt;FORMAT&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;[Date]&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;/SPAN&gt;&lt;SPAN&gt;"DD-MM-YYYY&lt;/SPAN&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;SPAN&gt;))&lt;BR /&gt;&lt;/SPAN&gt;&lt;BR /&gt;Here I am using format to avoid "variant type data" error:&lt;BR /&gt;&lt;img /&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
I hope this post helps to solve your issue and if it does consider accepting it as a solution and giving the post a thumbs up!&lt;BR /&gt;&lt;BR /&gt;My LinkedIn: &lt;A href="https://www.linkedin.com/in/n%C3%A4ttiahov-00001/" target="_blank"&gt;https://www.linkedin.com/in/n%C3%A4ttiahov-00001/&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/DIV&gt;
&lt;/DIV&gt;</description>
      <pubDate>Sun, 05 Mar 2023 14:21:01 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Text-for-past-and-Date-for-present-and-future/m-p/3112285#M110011</guid>
      <dc:creator>ValtteriN</dc:creator>
      <dc:date>2023-03-05T14:21:01Z</dc:date>
    </item>
    <item>
      <title>Re: Text for past and Date for present and future</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Text-for-past-and-Date-for-present-and-future/m-p/3112306#M110013</link>
      <description>&lt;P&gt;hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="92006" data-lia-user-login="joshua1990" class="lia-mention lia-mention-user"&gt;joshua1990&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;try to add a column like:&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;Column = IF([Date]&amp;lt;TODAY(), "Past", FORMAT([Date], "m/d/yyyy" ))&lt;/LI-CODE&gt;&lt;P&gt;it worked like:&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;the sequence of "m/d/yyyy" depends on your preference.&lt;/P&gt;</description>
      <pubDate>Sun, 05 Mar 2023 14:42:56 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Text-for-past-and-Date-for-present-and-future/m-p/3112306#M110013</guid>
      <dc:creator>FreemanZ</dc:creator>
      <dc:date>2023-03-05T14:42:56Z</dc:date>
    </item>
  </channel>
</rss>

