<?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 how to correctly filter blanks in Developer</title>
    <link>https://community.fabric.microsoft.com/t5/Developer/how-to-correctly-filter-blanks/m-p/192581#M6125</link>
    <description>&lt;P&gt;inside the&amp;nbsp;CALCULATE formula, I can use filters.&lt;/P&gt;&lt;P&gt;usually I filter blanks using:&lt;/P&gt;&lt;P&gt;data=BLANK()&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;But another developer here uses this:&lt;/P&gt;&lt;P&gt;LEN(data)=0&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Both filters return the same final value, but which filter is the correct one?&lt;/P&gt;&lt;P&gt;in my example, I am filtering off blank dates from my dataset.&lt;/P&gt;&lt;P&gt;How can I test this and be 100% sure of the correct filter?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Is NULL and BLANK the exactly same thing for Power BI? All related material I find shows only blanks, never shows null values.&lt;/P&gt;</description>
    <pubDate>Mon, 12 Jun 2017 20:44:10 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2017-06-12T20:44:10Z</dc:date>
    <item>
      <title>how to correctly filter blanks</title>
      <link>https://community.fabric.microsoft.com/t5/Developer/how-to-correctly-filter-blanks/m-p/192581#M6125</link>
      <description>&lt;P&gt;inside the&amp;nbsp;CALCULATE formula, I can use filters.&lt;/P&gt;&lt;P&gt;usually I filter blanks using:&lt;/P&gt;&lt;P&gt;data=BLANK()&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;But another developer here uses this:&lt;/P&gt;&lt;P&gt;LEN(data)=0&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Both filters return the same final value, but which filter is the correct one?&lt;/P&gt;&lt;P&gt;in my example, I am filtering off blank dates from my dataset.&lt;/P&gt;&lt;P&gt;How can I test this and be 100% sure of the correct filter?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Is NULL and BLANK the exactly same thing for Power BI? All related material I find shows only blanks, never shows null values.&lt;/P&gt;</description>
      <pubDate>Mon, 12 Jun 2017 20:44:10 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Developer/how-to-correctly-filter-blanks/m-p/192581#M6125</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2017-06-12T20:44:10Z</dc:date>
    </item>
    <item>
      <title>Re: how to correctly filter blanks</title>
      <link>https://community.fabric.microsoft.com/t5/Developer/how-to-correctly-filter-blanks/m-p/193586#M6171</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;@Anonymous&lt;/a&gt; wrote:&lt;BR /&gt;
&lt;P&gt;inside the&amp;nbsp;CALCULATE formula, I can use filters.&lt;/P&gt;
&lt;P&gt;usually I filter blanks using:&lt;/P&gt;
&lt;P&gt;data=BLANK()&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;But another developer here uses this:&lt;/P&gt;
&lt;P&gt;LEN(data)=0&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Both filters return the same final value, but which filter is the correct one?&lt;/P&gt;
&lt;P&gt;in my example, I am filtering off blank dates from my dataset.&lt;/P&gt;
&lt;P&gt;How can I test this and be 100% sure of the correct filter?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Is NULL and BLANK the exactly same thing for Power BI? All related material I find shows only blanks, never shows null values.&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;@Anonymous&lt;/a&gt;&lt;/P&gt;
&lt;P&gt;Power Query treats the empty("") and null as different, however, DAX seems to treat them as &amp;nbsp;the same.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Capture.PNG" style="width: 600px;"&gt;&lt;img src="https://community.fabric.microsoft.com/t5/image/serverpage/image-id/45561i4D4AC4F6759F2354/image-size/large?v=v2&amp;amp;px=999" role="button" title="Capture.PNG" alt="Capture.PNG" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;So the three in DAX shall work the same way.&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;Column = [a]=BLANK()

Column = [a]=""  //equal to LEN([a])=0

Column = LEN([a])=0 &lt;/PRE&gt;</description>
      <pubDate>Wed, 14 Jun 2017 02:08:39 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Developer/how-to-correctly-filter-blanks/m-p/193586#M6171</guid>
      <dc:creator>Eric_Zhang</dc:creator>
      <dc:date>2017-06-14T02:08:39Z</dc:date>
    </item>
    <item>
      <title>Re: how to correctly filter blanks</title>
      <link>https://community.fabric.microsoft.com/t5/Developer/how-to-correctly-filter-blanks/m-p/193967#M6177</link>
      <description>&lt;P&gt;thanks for your answer, but I asked DAX, and you showed M language inside Query Editor.&lt;/P&gt;&lt;P&gt;DAX is used only in the Report view for measures and calculates columns or tables. Inside Query Editor it is M language.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Anyway, if they both commands work the same way, when should I use one or another?&lt;/P&gt;</description>
      <pubDate>Wed, 14 Jun 2017 11:53:38 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Developer/how-to-correctly-filter-blanks/m-p/193967#M6177</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2017-06-14T11:53:38Z</dc:date>
    </item>
    <item>
      <title>Re: how to correctly filter blanks</title>
      <link>https://community.fabric.microsoft.com/t5/Developer/how-to-correctly-filter-blanks/m-p/194353#M6187</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;@Anonymous&lt;/a&gt; wrote:&lt;BR /&gt;
&lt;P&gt;thanks for your answer, but I asked DAX, and &lt;STRONG&gt;you showed M language inside Query Editor&lt;/STRONG&gt;.&lt;/P&gt;
&lt;P&gt;DAX is used only in the Report view for measures and calculates columns or tables. Inside Query Editor it is M language.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Anyway, if they both commands work the same way, &lt;STRONG&gt;when should I use one or another&lt;/STRONG&gt;?&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;@Anonymous&lt;/a&gt;&lt;/P&gt;
&lt;P&gt;I showed the null and empty("") difference in data model in M(Query Editor) and Data tab in report designer window, if you look into my snapshot carefully.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Though I think they're equal, I'd use BLANK() when I comparing/counting blank values and use &lt;A href="https://msdn.microsoft.com/en-us/library/ee634917.aspx" target="_self"&gt;LEN&lt;/A&gt; to compare text type(&lt;SPAN&gt;Returns the number of characters in a text string&lt;/SPAN&gt;) to make my DAX more comprehensible.&lt;/P&gt;</description>
      <pubDate>Thu, 15 Jun 2017 02:06:25 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Developer/how-to-correctly-filter-blanks/m-p/194353#M6187</guid>
      <dc:creator>Eric_Zhang</dc:creator>
      <dc:date>2017-06-15T02:06:25Z</dc:date>
    </item>
    <item>
      <title>Re: how to correctly filter blanks</title>
      <link>https://community.fabric.microsoft.com/t5/Developer/how-to-correctly-filter-blanks/m-p/2134514#M32369</link>
      <description>&lt;P&gt;I had a problem, that if I used BLANK() statement with int column, it filtered BLANK() and 0s as well.&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;instead: table[column]&lt;/SPAN&gt;&lt;SPAN&gt;&amp;nbsp;= BLANK()&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;use: LEN(table[column])&amp;nbsp;&amp;lt;&amp;gt; 0&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;SOLVED my problem&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 14 Oct 2021 09:17:35 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Developer/how-to-correctly-filter-blanks/m-p/2134514#M32369</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2021-10-14T09:17:35Z</dc:date>
    </item>
  </channel>
</rss>

