<?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 error support - True/False in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-error-support-True-False/m-p/4301852#M170817</link>
    <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="864347" data-lia-user-login="karenHO" class="lia-mention lia-mention-user"&gt;karenHO&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Can you please try the below dax:&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;KH Students on Roll 23/24 =
CALCULATE(
    COUNTROWS(STUDENT_SCHOOL_ENROLEMENTS), -- Counts students currently on roll
    STUDENT_SCHOOL_ENROLEMENTS[CURRENTLY_ON_ROLL] = TRUE, -- Filters students currently on roll
    ACADEMIC_CALENDAR_DATES[DATE] = DATE(2024, 5, 2) -- Filters for the specific date 2-May-2024
)&lt;/LI-CODE&gt;&lt;P&gt;Please let me know if it works for you.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Did I answer your question? Mark my post as a solution, this will help others!&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;If my response(s) assisted you in any way, don't forget to drop me a "&lt;STRONG&gt;Kudos&lt;/STRONG&gt;" &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Kind Regards,&lt;BR /&gt;Poojara&lt;BR /&gt;Data Analyst | MSBI Developer | Power BI Consultant&lt;BR /&gt;&lt;STRONG&gt;Please Subscribe my YouTube for Beginners/Advance Concepts:&lt;/STRONG&gt;&amp;nbsp;&lt;A href="https://youtube.com/@biconcepts?si=04iw9SYI2HN80HKS" target="_self"&gt;https://youtube.com/@biconcepts?si=04iw9SYI2HN80HKS&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Tue, 26 Nov 2024 09:39:38 GMT</pubDate>
    <dc:creator>Poojara_D12</dc:creator>
    <dc:date>2024-11-26T09:39:38Z</dc:date>
    <item>
      <title>DAX error support - True/False</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-error-support-True-False/m-p/4300406#M170768</link>
      <description>&lt;P&gt;I am trying to create a DAX formula that will count the number of students on roll in a school last school year specifically on 2MAY24.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Gemini has offered the below but I'm getting a&amp;nbsp;&lt;EM&gt;The True/False expression does not specify a column. Each True/False expressions used as a table filter expression must refer to exactly one column&lt;/EM&gt; error.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;KH Students on Roll &lt;/SPAN&gt;&lt;SPAN&gt;23&lt;/SPAN&gt;&lt;SPAN&gt;/&lt;/SPAN&gt;&lt;SPAN&gt;24&lt;/SPAN&gt;&lt;SPAN&gt;&amp;nbsp;= &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;CALCULATE (&lt;BR /&gt;COUNTROWS ( ACADEMIC_CALENDAR_DATES ),&lt;BR /&gt;ACADEMIC_CALENDAR_DATES[STUDENT_ON_ROLL] = TRUE,&lt;BR /&gt;ACADEMIC_CALENDAR_DATES[STUDENT_ON_ROLL] = "May",&lt;BR /&gt;HASONEVALUE ( STUDENT_SCHOOL_ENROLEMENTS[CURRENTLY_ON_ROLL] ),&lt;BR /&gt;STUDENT_SCHOOL_ENROLEMENTS[CURRENTLY_ON_ROLL] = TRUE&lt;BR /&gt;)&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;I'm a real beginner to DAX so not quite sure how to get it to count just for May.&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;Any ideas ??&lt;/DIV&gt;&lt;/DIV&gt;</description>
      <pubDate>Mon, 25 Nov 2024 18:01:07 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-error-support-True-False/m-p/4300406#M170768</guid>
      <dc:creator>karenHO</dc:creator>
      <dc:date>2024-11-25T18:01:07Z</dc:date>
    </item>
    <item>
      <title>Re: DAX error support - True/False</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-error-support-True-False/m-p/4300512#M170773</link>
      <description>&lt;P&gt;You cannot use HASONEVALUE in that situation.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Instead, create a table variable that applies your filters, and adds the number of "currently on roll") field. Then filter that table variable by the field being equal to 1, and then return the countrows of that.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 25 Nov 2024 20:02:04 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-error-support-True-False/m-p/4300512#M170773</guid>
      <dc:creator>lbendlin</dc:creator>
      <dc:date>2024-11-25T20:02:04Z</dc:date>
    </item>
    <item>
      <title>Re: DAX error support - True/False</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-error-support-True-False/m-p/4301852#M170817</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="864347" data-lia-user-login="karenHO" class="lia-mention lia-mention-user"&gt;karenHO&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Can you please try the below dax:&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;KH Students on Roll 23/24 =
CALCULATE(
    COUNTROWS(STUDENT_SCHOOL_ENROLEMENTS), -- Counts students currently on roll
    STUDENT_SCHOOL_ENROLEMENTS[CURRENTLY_ON_ROLL] = TRUE, -- Filters students currently on roll
    ACADEMIC_CALENDAR_DATES[DATE] = DATE(2024, 5, 2) -- Filters for the specific date 2-May-2024
)&lt;/LI-CODE&gt;&lt;P&gt;Please let me know if it works for you.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Did I answer your question? Mark my post as a solution, this will help others!&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;If my response(s) assisted you in any way, don't forget to drop me a "&lt;STRONG&gt;Kudos&lt;/STRONG&gt;" &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Kind Regards,&lt;BR /&gt;Poojara&lt;BR /&gt;Data Analyst | MSBI Developer | Power BI Consultant&lt;BR /&gt;&lt;STRONG&gt;Please Subscribe my YouTube for Beginners/Advance Concepts:&lt;/STRONG&gt;&amp;nbsp;&lt;A href="https://youtube.com/@biconcepts?si=04iw9SYI2HN80HKS" target="_self"&gt;https://youtube.com/@biconcepts?si=04iw9SYI2HN80HKS&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 26 Nov 2024 09:39:38 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-error-support-True-False/m-p/4301852#M170817</guid>
      <dc:creator>Poojara_D12</dc:creator>
      <dc:date>2024-11-26T09:39:38Z</dc:date>
    </item>
    <item>
      <title>Re: DAX error support - True/False</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-error-support-True-False/m-p/4303550#M170876</link>
      <description>&lt;P&gt;Hi ALL&lt;/P&gt;
&lt;P&gt;Firstly&amp;nbsp; Poojara_D12&amp;nbsp; and&amp;nbsp; lbendlin&amp;nbsp; thank you for your solution!&lt;BR /&gt;And&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="864347" data-lia-user-login="karenHO" class="lia-mention lia-mention-user"&gt;karenHO&lt;/a&gt;&amp;nbsp;,The problem you encountered seems to be because ACADEMIC_CALENDAR_DATES[STUDENT_ON_ROLL] is referenced twice in the dax and is assigned a different value, I tried to improve your DAX as follows, I hope that helps you.&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;KH Students on Roll 23/24 = 
CALCULATE (
    COUNTROWS ( Student_School_Enrollments_Data ),
    Academic_Calendar_Dates_Data[DATE] = DATE(2024, 5, 2),
    Academic_Calendar_Dates_Data[STUDENT_ON_ROLL] = TRUE,
    Student_School_Enrollments_Data[CURRENTLY_ON_ROLL] = TRUE
)&lt;/LI-CODE&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;If you have more recent questions, you can check my pbix file to see if my example data meets your expectations, and I would be honored if my solution solves your problem!&lt;/P&gt;
&lt;P&gt;Hope it helps!&lt;/P&gt;
&lt;P&gt;Best regards,&lt;BR /&gt;Community Support Team_ Tom Shen&lt;/P&gt;
&lt;P&gt;If this post helps then please consider&amp;nbsp;&lt;STRONG&gt;Accept it as the solution&lt;/STRONG&gt;&amp;nbsp;to help the other members find it more quickly.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 27 Nov 2024 06:55:57 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-error-support-True-False/m-p/4303550#M170876</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2024-11-27T06:55:57Z</dc:date>
    </item>
    <item>
      <title>Re: DAX error support - True/False</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-error-support-True-False/m-p/4315642#M171363</link>
      <description>&lt;P&gt;Hi Thanks for this.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have used the below formula but I am now getting an error -&amp;nbsp;&lt;EM&gt;A function 'PLACEHOLDER' has been used in a True/Fasle expression that is used as a table filter expressions.&amp;nbsp; This is not allowed.&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;Any ideas?&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;KH Students on Roll &lt;/SPAN&gt;&lt;SPAN&gt;23&lt;/SPAN&gt;&lt;SPAN&gt;/&lt;/SPAN&gt;&lt;SPAN&gt;24&lt;/SPAN&gt;&lt;SPAN&gt; = &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;CALCULATE&lt;/SPAN&gt;&lt;SPAN&gt; (&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;COUNTROWS&lt;/SPAN&gt;&lt;SPAN&gt; (STUDENT_SCHOOL_ENROLMENTS ),&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; ACADEMIC_CALENDAR_DATES[DATE] = &lt;/SPAN&gt;&lt;SPAN&gt;DATE&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;2024&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;5&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;2&lt;/SPAN&gt;&lt;SPAN&gt;),&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; ACADEMIC_CALENDAR_DATES[Student_On_Roll] = TRUE,&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; STUDENT_SCHOOL_ENROLMENTS[CURRENTLY_ON_ROLL] = TRUE&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;</description>
      <pubDate>Thu, 05 Dec 2024 17:20:52 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-error-support-True-False/m-p/4315642#M171363</guid>
      <dc:creator>karenHO</dc:creator>
      <dc:date>2024-12-05T17:20:52Z</dc:date>
    </item>
    <item>
      <title>Re: DAX error support - True/False</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-error-support-True-False/m-p/4315654#M171364</link>
      <description>&lt;P&gt;This one has sort of worked, however it is only bringing those students who were 'currently on roll' on 2MAY24.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I want to know all students that were 'currently on roll' on 2MAY24, not just those that were first enrolled on 2MAY24.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;any ideas?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 05 Dec 2024 17:26:38 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-error-support-True-False/m-p/4315654#M171364</guid>
      <dc:creator>karenHO</dc:creator>
      <dc:date>2024-12-05T17:26:38Z</dc:date>
    </item>
  </channel>
</rss>

