<?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 DAX Percentage of actions completed on time in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-Percentage-of-actions-completed-on-time/m-p/3937897#M153141</link>
    <description>&lt;P&gt;Good Afternoon (Newbie here)&lt;/P&gt;&lt;P&gt;I'm trying to create a card for my dashboard that shows percentage (% value only) of actions completed on time.&lt;/P&gt;&lt;P&gt;So far I have created a claulated column for the completed on time, however there are blanks that appear in the result as being completed on time which need to be excluded from the count.&lt;/P&gt;&lt;P&gt;I was thinking i might nest the ALLNOBLANK function in the current if statement, but i'm a tad lost in the next steps.&amp;nbsp;&lt;/P&gt;&lt;P&gt;This is the current Dax I have in Power Bi&lt;/P&gt;&lt;P&gt;= IF('Corrective Actions'[Action - Date Due]&amp;gt;=('Corrective Actions'[Action - Date Completed]),"yes",if('Corrective Actions'[Action - Date Due]&amp;lt;=('Corrective Actions'[Action - Date Completed]),"No"))&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Any guidace to this would be great as a pie chart with filters is not the ideal visual I'm seeking.&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;I'd like to contidionally format the percentage card value based on it's value ranges&lt;/P&gt;&lt;P&gt;Thank you in advance&lt;/P&gt;</description>
    <pubDate>Wed, 22 May 2024 04:59:58 GMT</pubDate>
    <dc:creator>angem</dc:creator>
    <dc:date>2024-05-22T04:59:58Z</dc:date>
    <item>
      <title>DAX Percentage of actions completed on time</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-Percentage-of-actions-completed-on-time/m-p/3937897#M153141</link>
      <description>&lt;P&gt;Good Afternoon (Newbie here)&lt;/P&gt;&lt;P&gt;I'm trying to create a card for my dashboard that shows percentage (% value only) of actions completed on time.&lt;/P&gt;&lt;P&gt;So far I have created a claulated column for the completed on time, however there are blanks that appear in the result as being completed on time which need to be excluded from the count.&lt;/P&gt;&lt;P&gt;I was thinking i might nest the ALLNOBLANK function in the current if statement, but i'm a tad lost in the next steps.&amp;nbsp;&lt;/P&gt;&lt;P&gt;This is the current Dax I have in Power Bi&lt;/P&gt;&lt;P&gt;= IF('Corrective Actions'[Action - Date Due]&amp;gt;=('Corrective Actions'[Action - Date Completed]),"yes",if('Corrective Actions'[Action - Date Due]&amp;lt;=('Corrective Actions'[Action - Date Completed]),"No"))&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Any guidace to this would be great as a pie chart with filters is not the ideal visual I'm seeking.&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;I'd like to contidionally format the percentage card value based on it's value ranges&lt;/P&gt;&lt;P&gt;Thank you in advance&lt;/P&gt;</description>
      <pubDate>Wed, 22 May 2024 04:59:58 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-Percentage-of-actions-completed-on-time/m-p/3937897#M153141</guid>
      <dc:creator>angem</dc:creator>
      <dc:date>2024-05-22T04:59:58Z</dc:date>
    </item>
    <item>
      <title>Re: DAX Percentage of actions completed on time</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-Percentage-of-actions-completed-on-time/m-p/3941526#M153245</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="712634" data-lia-user-login="angem" class="lia-mention lia-mention-user"&gt;angem&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;
&lt;P&gt;I would suggest that you create measures instead of calculated columns. I created a sample data to help you with your problem, you can try adding the following measures.&lt;/P&gt;
&lt;P&gt;Sample data:&lt;/P&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;Add new measures:&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;Yes = 
VAR TotalActions =
    CALCULATE (
        COUNTROWS ( 'Corrective Actions' ),
        NOT ( ISBLANK ( 'Corrective Actions'[Action - Date Completed] ) )
    )
VAR CompletedTimely =
    CALCULATE (
        COUNTROWS ( 'Corrective Actions' ),
        'Corrective Actions'[Action - Date Due] &amp;gt;= 'Corrective Actions'[Action - Date Completed],
        NOT ( ISBLANK ( 'Corrective Actions'[Action - Date Completed] ) )
    )
RETURN
    DIVIDE ( CompletedTimely, TotalActions )
&lt;/LI-CODE&gt;&lt;LI-CODE lang="markup"&gt;No = 
VAR TotalActions =
    CALCULATE (
        COUNTROWS ( 'Corrective Actions' ),
        NOT ( ISBLANK ( 'Corrective Actions'[Action - Date Completed] ) )
    )
VAR CompletedUntimely =
    CALCULATE (
        COUNTROWS ( 'Corrective Actions' ),
        'Corrective Actions'[Action - Date Due] &amp;lt;= 'Corrective Actions'[Action - Date Completed],
        NOT ( ISBLANK ( 'Corrective Actions'[Action - Date Completed] ) )
    )
RETURN
    DIVIDE ( CompletedUntimely, TotalActions )
&lt;/LI-CODE&gt;
&lt;P&gt;Final output:&lt;/P&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;&lt;A href="https://community.fabric.microsoft.com/t5/Community-Blog/How-to-Get-Your-Question-Answered-Quickly/ba-p/38490" target="_blank" rel="noopener"&gt;How to Get Your Question Answered Quickly - Microsoft Fabric Community&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;If it does not help, please provide more details with your desired out put and pbix file without privacy information.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Best Regards,&lt;/P&gt;
&lt;P&gt;Ada Wang&lt;/P&gt;
&lt;P&gt;If this post&amp;nbsp;&lt;EM&gt;&lt;STRONG&gt;helps&lt;/STRONG&gt;&lt;/EM&gt;, then please consider&lt;EM&gt;&lt;STRONG&gt;&amp;nbsp;Accept it as the solution&amp;nbsp;&lt;/STRONG&gt;&lt;/EM&gt;to help the other members find it more quickly.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 23 May 2024 05:27:00 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-Percentage-of-actions-completed-on-time/m-p/3941526#M153245</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2024-05-23T05:27:00Z</dc:date>
    </item>
    <item>
      <title>Re: DAX Percentage of actions completed on time</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-Percentage-of-actions-completed-on-time/m-p/3950305#M153428</link>
      <description>&lt;P&gt;Very much appreciate your guidance here Ada, thank you!! What a great way to start the week, your DAX solved my questions above.&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Ange&lt;/P&gt;</description>
      <pubDate>Sun, 26 May 2024 20:46:30 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-Percentage-of-actions-completed-on-time/m-p/3950305#M153428</guid>
      <dc:creator>angem</dc:creator>
      <dc:date>2024-05-26T20:46:30Z</dc:date>
    </item>
  </channel>
</rss>

