<?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 Time Intelligence Function is not working with Date table in Custom Visuals Development Discussion</title>
    <link>https://community.fabric.microsoft.com/t5/Custom-Visuals-Development/Time-Intelligence-Function-is-not-working-with-Date-table/m-p/1680347#M3581</link>
    <description>&lt;P&gt;I have a date table in my dataset. It is marked as date table.&amp;nbsp;&lt;BR /&gt;I need to calculate last year count. I uses SAMEPERIODLASTYEAR() function. ALso tried with other time intelligence functions also. But it is not given the last year count.&lt;/P&gt;&lt;P&gt;The following are the two measures that I have used in two different ways:&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;EM&gt;last_year_member_count = CALCULATE(COUNT('All Members'[Full Name]) - CALCULATE(COUNT('All Members'[Full Name]), 'All Members'[Member Status New] = "D"), FILTER('All Members', SAMEPERIODLASTYEAR('Date'[Date])))&lt;/EM&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;&lt;EM&gt;last_year_member_count =&lt;/EM&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;EM&gt;var member_count = CALCULATE(COUNT('All Members'[Full Name]), SAMEPERIODLASTYEAR('Date'[Date]))&lt;/EM&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;EM&gt;var member_is_D = CALCULATE(COUNT('All Members'[Full Name]), 'All Members'[Member Status New] = "D", SAMEPERIODLASTYEAR('Date'[Date]))&lt;/EM&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;EM&gt;var member_not_D = member_count - member_is_D&lt;/EM&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;EM&gt;return member_not_D&lt;/EM&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;/DIV&gt;</description>
    <pubDate>Mon, 22 Feb 2021 09:06:15 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2021-02-22T09:06:15Z</dc:date>
    <item>
      <title>Time Intelligence Function is not working with Date table</title>
      <link>https://community.fabric.microsoft.com/t5/Custom-Visuals-Development/Time-Intelligence-Function-is-not-working-with-Date-table/m-p/1680347#M3581</link>
      <description>&lt;P&gt;I have a date table in my dataset. It is marked as date table.&amp;nbsp;&lt;BR /&gt;I need to calculate last year count. I uses SAMEPERIODLASTYEAR() function. ALso tried with other time intelligence functions also. But it is not given the last year count.&lt;/P&gt;&lt;P&gt;The following are the two measures that I have used in two different ways:&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;EM&gt;last_year_member_count = CALCULATE(COUNT('All Members'[Full Name]) - CALCULATE(COUNT('All Members'[Full Name]), 'All Members'[Member Status New] = "D"), FILTER('All Members', SAMEPERIODLASTYEAR('Date'[Date])))&lt;/EM&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;&lt;EM&gt;last_year_member_count =&lt;/EM&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;EM&gt;var member_count = CALCULATE(COUNT('All Members'[Full Name]), SAMEPERIODLASTYEAR('Date'[Date]))&lt;/EM&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;EM&gt;var member_is_D = CALCULATE(COUNT('All Members'[Full Name]), 'All Members'[Member Status New] = "D", SAMEPERIODLASTYEAR('Date'[Date]))&lt;/EM&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;EM&gt;var member_not_D = member_count - member_is_D&lt;/EM&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;EM&gt;return member_not_D&lt;/EM&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;/DIV&gt;</description>
      <pubDate>Mon, 22 Feb 2021 09:06:15 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Custom-Visuals-Development/Time-Intelligence-Function-is-not-working-with-Date-table/m-p/1680347#M3581</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2021-02-22T09:06:15Z</dc:date>
    </item>
  </channel>
</rss>

