<?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 when slicer is not selected then null in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-when-slicer-is-not-selected-then-null/m-p/3576841#M137918</link>
    <description>&lt;P&gt;Assuming you have a date slicer and a customer number slicer, and you want your table to show values only when both a date and a customer number are selected, you can create a measure that checks if the slicers have selections and then display the values accordingly.&lt;/P&gt;&lt;P&gt;Here's an example of how you might structure your DAX measure:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;YourMeasure =&lt;BR /&gt;IF (&lt;BR /&gt;ISFILTERED('DateTable'[DateColumn]) &amp;amp;&amp;amp; ISFILTERED('CustomerTable'[CustomerNumberColumn]),&lt;BR /&gt;-- Show your values here when both slicers are selected&lt;BR /&gt;SUM('YourDataTable'[YourValueColumn]),&lt;BR /&gt;-- Show null when either or both slicers are not selected&lt;BR /&gt;BLANK()&lt;BR /&gt;)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;In this example:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;'DateTable'[DateColumn] and 'CustomerTable'[CustomerNumberColumn] are the columns from your date and customer tables that correspond to the slicers.&lt;/LI&gt;&lt;LI&gt;'YourDataTable'[YourValueColumn] is the column in your data table that you want to display when both slicers are selected.&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;This DAX measure checks if both slicers are filtered (ISFILTERED function) and, if so, displays the sum of your values; otherwise, it displays BLANK().&lt;/P&gt;&lt;P&gt;You can adjust this DAX code based on your specific data model and column names. Remember to replace the placeholder table and column names with your actual table and column names.&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;If this post&amp;nbsp;helps, then please consider&amp;nbsp;Accepting it as the solution&amp;nbsp;to help the other members find it more quickly.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;In case there is still a problem, please feel free and explain your issue in detail,&amp;nbsp;It will be my pleasure to assist you in any way I can.&lt;/STRONG&gt;&lt;/P&gt;</description>
    <pubDate>Mon, 11 Dec 2023 05:41:45 GMT</pubDate>
    <dc:creator>123abc</dc:creator>
    <dc:date>2023-12-11T05:41:45Z</dc:date>
    <item>
      <title>DAX when slicer is not selected then null</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-when-slicer-is-not-selected-then-null/m-p/3576581#M137899</link>
      <description>&lt;P&gt;I have a direct query to my data set yet I need the follwoing:&lt;/P&gt;&lt;P&gt;When there is no value selected in the slicer for example when there is no date selected or there is no customer number selected then my table should rest in null and only show values if the user selects a date and a customer number.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;</description>
      <pubDate>Mon, 11 Dec 2023 01:46:17 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-when-slicer-is-not-selected-then-null/m-p/3576581#M137899</guid>
      <dc:creator>c_d_m</dc:creator>
      <dc:date>2023-12-11T01:46:17Z</dc:date>
    </item>
    <item>
      <title>Re: DAX when slicer is not selected then null</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-when-slicer-is-not-selected-then-null/m-p/3576841#M137918</link>
      <description>&lt;P&gt;Assuming you have a date slicer and a customer number slicer, and you want your table to show values only when both a date and a customer number are selected, you can create a measure that checks if the slicers have selections and then display the values accordingly.&lt;/P&gt;&lt;P&gt;Here's an example of how you might structure your DAX measure:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;YourMeasure =&lt;BR /&gt;IF (&lt;BR /&gt;ISFILTERED('DateTable'[DateColumn]) &amp;amp;&amp;amp; ISFILTERED('CustomerTable'[CustomerNumberColumn]),&lt;BR /&gt;-- Show your values here when both slicers are selected&lt;BR /&gt;SUM('YourDataTable'[YourValueColumn]),&lt;BR /&gt;-- Show null when either or both slicers are not selected&lt;BR /&gt;BLANK()&lt;BR /&gt;)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;In this example:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;'DateTable'[DateColumn] and 'CustomerTable'[CustomerNumberColumn] are the columns from your date and customer tables that correspond to the slicers.&lt;/LI&gt;&lt;LI&gt;'YourDataTable'[YourValueColumn] is the column in your data table that you want to display when both slicers are selected.&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;This DAX measure checks if both slicers are filtered (ISFILTERED function) and, if so, displays the sum of your values; otherwise, it displays BLANK().&lt;/P&gt;&lt;P&gt;You can adjust this DAX code based on your specific data model and column names. Remember to replace the placeholder table and column names with your actual table and column names.&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;If this post&amp;nbsp;helps, then please consider&amp;nbsp;Accepting it as the solution&amp;nbsp;to help the other members find it more quickly.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;In case there is still a problem, please feel free and explain your issue in detail,&amp;nbsp;It will be my pleasure to assist you in any way I can.&lt;/STRONG&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 11 Dec 2023 05:41:45 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-when-slicer-is-not-selected-then-null/m-p/3576841#M137918</guid>
      <dc:creator>123abc</dc:creator>
      <dc:date>2023-12-11T05:41:45Z</dc:date>
    </item>
  </channel>
</rss>

