<?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: Dax Query help in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Dax-Query-help/m-p/3137384#M111882</link>
    <description>&lt;P&gt;&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;&lt;/P&gt;</description>
    <pubDate>Thu, 16 Mar 2023 22:19:23 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2023-03-16T22:19:23Z</dc:date>
    <item>
      <title>Dax Query help</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Dax-Query-help/m-p/3137342#M111876</link>
      <description>&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;SUMX&lt;/SPAN&gt;&lt;SPAN&gt;('Table (2)',&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;IF&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;AND&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;NOT&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;ISBLANK&lt;/SPAN&gt;&lt;SPAN&gt;([Current Year Value])),&lt;/SPAN&gt;&lt;SPAN&gt;NOT&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;ISBLANK&lt;/SPAN&gt;&lt;SPAN&gt;([Previous Year Value]))),&lt;/SPAN&gt;&lt;SPAN&gt;0&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;SWITCH&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;TRUE&lt;/SPAN&gt;&lt;SPAN&gt;(),&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;ISBLANK&lt;/SPAN&gt;&lt;SPAN&gt;([Current Year Value]),[Previous Year Value],&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;ISBLANK&lt;/SPAN&gt;&lt;SPAN&gt;([Previous Year Value]),[Current Year Value],&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;0&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; )&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; )&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; )&lt;BR /&gt;Above if statement doesn't return 0. It summing Currentyearvalue+ previousyearvalue and retrun but it supposed to return 0 according to logic. Is there any idea to fix?&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;</description>
      <pubDate>Fri, 17 Mar 2023 13:16:03 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Dax-Query-help/m-p/3137342#M111876</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2023-03-17T13:16:03Z</dc:date>
    </item>
    <item>
      <title>Re: Dax Query help</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Dax-Query-help/m-p/3137370#M111879</link>
      <description>&lt;P&gt;Anonymous&lt;/a&gt;&amp;nbsp;Sample data would help along with measure formulas or is this a calculated column? Could be that your columns/measures aren't really blank?&lt;/P&gt;</description>
      <pubDate>Thu, 16 Mar 2023 22:08:18 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Dax-Query-help/m-p/3137370#M111879</guid>
      <dc:creator>Greg_Deckler</dc:creator>
      <dc:date>2023-03-16T22:08:18Z</dc:date>
    </item>
    <item>
      <title>Re: Dax Query help</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Dax-Query-help/m-p/3137380#M111881</link>
      <description>&lt;P&gt;It is a measure. Currentyear and Previousyear are measure as well. I am checking if those measures are not blank in the table I want to obtain 0 as a value and then not adding in the total value. I will attach the screenshot&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 16 Mar 2023 22:22:36 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Dax-Query-help/m-p/3137380#M111881</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2023-03-16T22:22:36Z</dc:date>
    </item>
    <item>
      <title>Re: Dax Query help</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Dax-Query-help/m-p/3137384#M111882</link>
      <description>&lt;P&gt;&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;&lt;/P&gt;</description>
      <pubDate>Thu, 16 Mar 2023 22:19:23 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Dax-Query-help/m-p/3137384#M111882</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2023-03-16T22:19:23Z</dc:date>
    </item>
    <item>
      <title>Re: Dax Query help</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Dax-Query-help/m-p/3139059#M112002</link>
      <description>&lt;P&gt;Anonymous&lt;/a&gt;&amp;nbsp;Why not just +0 to the RETURN value for your measures?&lt;/P&gt;</description>
      <pubDate>Fri, 17 Mar 2023 14:08:41 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Dax-Query-help/m-p/3139059#M112002</guid>
      <dc:creator>Greg_Deckler</dc:creator>
      <dc:date>2023-03-17T14:08:41Z</dc:date>
    </item>
    <item>
      <title>Re: Dax Query help</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Dax-Query-help/m-p/3139091#M112003</link>
      <description>&lt;P&gt;&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;If I understood you correctly I modified if condtion with +0 but it is not working. It seems to me not applying If condition for some reason&lt;/P&gt;</description>
      <pubDate>Fri, 17 Mar 2023 14:17:56 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Dax-Query-help/m-p/3139091#M112003</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2023-03-17T14:17:56Z</dc:date>
    </item>
    <item>
      <title>Re: Dax Query help</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Dax-Query-help/m-p/3139282#M112015</link>
      <description>&lt;P&gt;Anonymous&lt;/a&gt;&amp;nbsp;I was referring to +0 on your base measures so that you don't have to check for blank and return 0, they will just be 0 if they are blank because of the +0.&lt;/P&gt;</description>
      <pubDate>Fri, 17 Mar 2023 15:41:17 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Dax-Query-help/m-p/3139282#M112015</guid>
      <dc:creator>Greg_Deckler</dc:creator>
      <dc:date>2023-03-17T15:41:17Z</dc:date>
    </item>
    <item>
      <title>Re: Dax Query help</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Dax-Query-help/m-p/3139400#M112020</link>
      <description>&lt;P&gt;&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;The logic is that if currentyear and previousyear have value I need to skip or returen 0. They shouldn't be part of meaure in the table and then total will be calculated correctly, that's the reason I am implemnting if logic to assign 0 if they both have value. I hope it makes more sense now.&lt;/P&gt;</description>
      <pubDate>Fri, 17 Mar 2023 16:25:24 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Dax-Query-help/m-p/3139400#M112020</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2023-03-17T16:25:24Z</dc:date>
    </item>
    <item>
      <title>Re: Dax Query help</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Dax-Query-help/m-p/3139437#M112025</link>
      <description>&lt;P&gt;Anonymous&lt;/a&gt;&amp;nbsp;Ahhh, OK so try something like this instead:&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;SUMX('Table (2)',
  SWITCH(TRUE(),
    [Current Year Value] &amp;gt; 0 &amp;amp;&amp;amp; [Previous Year Value] &amp;gt; 0,0,
    [Current Year Value] &amp;gt; 0,[Previous Year Value],
    [Previous Year Value] &amp;gt; 0,[Current Year Value],
    0
  )&lt;/LI-CODE&gt;
&lt;P&gt;If that's not it, will need sample data as text and the formulas for your measures.&lt;/P&gt;</description>
      <pubDate>Fri, 17 Mar 2023 16:45:25 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Dax-Query-help/m-p/3139437#M112025</guid>
      <dc:creator>Greg_Deckler</dc:creator>
      <dc:date>2023-03-17T16:45:25Z</dc:date>
    </item>
    <item>
      <title>Re: Dax Query help</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Dax-Query-help/m-p/3139496#M112033</link>
      <description>&lt;P&gt;&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; it didn't work. It returns each row 0 . I will copy the measures fromula&amp;nbsp; but I coudn't see any option to upload and file for sample data.&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;Current Year Value =&lt;/P&gt;&lt;P&gt;VAR curYear = YEAR(TODAY()) //Current Year&lt;BR /&gt;VAR nxtYear = YEAR(TODAY())+1 //Next Year&lt;BR /&gt;VAR fclYear =&lt;BR /&gt;IF(MONTH(TODAY()) &amp;lt; 2,&lt;BR /&gt;curYear,&lt;BR /&gt;nxtYear)&lt;BR /&gt;return&lt;BR /&gt;CALCULATE(SUM(table 2[Value]),FILTER((DATE_TABLE),VALUE(DATE_TABLE[Fiscal Year])=fclYear))&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Previous Year value =&lt;BR /&gt;VAR curYear = YEAR(TODAY()) //Current Year&lt;BR /&gt;VAR nxtYear = YEAR(TODAY())+1 //Next Year&lt;BR /&gt;VAR fclYear =&lt;BR /&gt;IF(MONTH(TODAY()) &amp;lt; 2,&lt;BR /&gt;curYear,&lt;BR /&gt;nxtYear)&lt;BR /&gt;return&lt;BR /&gt;CALCULATE(SUM(table 2[Value]),FILTER((DATE_TABLE),VALUE(DATE_TABLE[Fiscal Year])=fclYear-1))&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;P/N =&lt;/P&gt;&lt;P&gt;SUMX(Table 2,&lt;BR /&gt;IF(AND(NOT(ISBLANK([Current Year Value])),NOT(ISBLANK([Previous Year Value]))),0,&lt;BR /&gt;SWITCH(&lt;BR /&gt;TRUE(),&lt;BR /&gt;ISBLANK([Current Year Value]),[Previous Year Value],&lt;BR /&gt;ISBLANK([Previous Year Value]),[Current Year Value]&lt;BR /&gt;&lt;BR /&gt;)&lt;/P&gt;&lt;P&gt;)&lt;BR /&gt;)&lt;/P&gt;</description>
      <pubDate>Fri, 17 Mar 2023 17:24:07 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Dax-Query-help/m-p/3139496#M112033</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2023-03-17T17:24:07Z</dc:date>
    </item>
  </channel>
</rss>

