<?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: Retrive Second Working Day in PowerBI in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Retrive-Second-Working-Day-in-PowerBI/m-p/3546091#M136345</link>
    <description>&lt;P&gt;hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="650045" data-lia-user-login="MONSTER123" class="lia-mention lia-mention-user"&gt;MONSTER123&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;not sure if i fully get you, supposing your dates table is like:&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;dates = CALENDAR(DATE(2023, 11, 1), DATE(2024, 2, 5))&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;try to add a calculated column like below:&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;2ndWD = 
VAR _currentdate = [date]
VAR _workdaysinmonth= 
FILTER(
    dates,
    MONTH(dates[date]) = MONTH(_currentdate)
        &amp;amp;&amp;amp;YEAR(dates[date]) = YEAR(_currentdate)
        &amp;amp;&amp;amp;NOT WEEKDAY(dates[date], 2) IN  {6, 7}
)
VAR _firstworkday = MINX(TOPN(1, _workdaysinmonth, [date], ASC), [date])
VAR _secondworkday = MINX(FILTER(_workdaysinmonth, [date]&amp;gt;_firstworkday), [date])
VAR _result = IF(_currentdate = _secondworkday, "yes", "no")
RETURN _result&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;it worked like:&lt;/P&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Wed, 22 Nov 2023 05:59:38 GMT</pubDate>
    <dc:creator>FreemanZ</dc:creator>
    <dc:date>2023-11-22T05:59:38Z</dc:date>
    <item>
      <title>Retrive Second Working Day in PowerBI</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Retrive-Second-Working-Day-in-PowerBI/m-p/3545955#M136338</link>
      <description>&lt;P&gt;Hi,&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have imported all my daily&amp;nbsp;&lt;SPAN&gt;reports into my powerbi.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;I would like to have one dashboard with all the reports that dated every 2nd weekday of the month.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;How can I create a formula to retrieve all the 2nd weekday of the month.&lt;/P&gt;&lt;P&gt;In Excel formula :&amp;nbsp;&lt;SPAN&gt;=WORKDAY(DATE(YEAR(A1),MONTH(A&lt;/SPAN&gt;&lt;SPAN&gt;1),1)-1,2)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;For example:&lt;/P&gt;&lt;P&gt;I need to get the report that is dated dated &lt;STRONG&gt;02.11.2023&lt;/STRONG&gt; for &lt;STRONG&gt;Nov 2023&lt;/STRONG&gt; and &lt;STRONG&gt;04.12.2023&lt;/STRONG&gt; for &lt;STRONG&gt;Dec 2023&lt;/STRONG&gt;,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank You for your kind assistance!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 22 Nov 2023 03:28:03 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Retrive-Second-Working-Day-in-PowerBI/m-p/3545955#M136338</guid>
      <dc:creator>MONSTER123</dc:creator>
      <dc:date>2023-11-22T03:28:03Z</dc:date>
    </item>
    <item>
      <title>Re: Retrive Second Working Day in PowerBI</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Retrive-Second-Working-Day-in-PowerBI/m-p/3545994#M136341</link>
      <description>&lt;P&gt;Hi, I am not sure how your semantic model looks like, but I tried to create a sample pbix file like below.&lt;/P&gt;
&lt;P&gt;Please check the below picture and the attached pbix file.&lt;/P&gt;
&lt;P&gt;I hope the below can provide some ideas on how to create a solution for your semantic model.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;A href="https://learn.microsoft.com/en-us/dax/index-function-dax?wt.mc_id=DP-MVP-5004989" target="_blank"&gt;INDEX function (DAX) - DAX | Microsoft Learn&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;Expected result measure: =
VAR _t =
    FILTER (
        SUMMARIZE (
            ALL ( Sales ),
            'Calendar'[Date],
            'Calendar'[Weekday name sort],
            'Calendar'[Year-Month sort]
        ),
        NOT ( 'Calendar'[Weekday name sort] IN { 1, 7 } )
    )
RETURN
    CALCULATE (
        SUM ( Sales[Quantity] ),
        KEEPFILTERS (
            INDEX (
                2,
                _t,
                ORDERBY ( 'Calendar'[Date], ASC ),
                ,
                PARTITIONBY ( 'Calendar'[Year-Month sort] )
            )
        )
    )
&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 22 Nov 2023 04:11:08 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Retrive-Second-Working-Day-in-PowerBI/m-p/3545994#M136341</guid>
      <dc:creator>Jihwan_Kim</dc:creator>
      <dc:date>2023-11-22T04:11:08Z</dc:date>
    </item>
    <item>
      <title>Re: Retrive Second Working Day in PowerBI</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Retrive-Second-Working-Day-in-PowerBI/m-p/3546091#M136345</link>
      <description>&lt;P&gt;hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="650045" data-lia-user-login="MONSTER123" class="lia-mention lia-mention-user"&gt;MONSTER123&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;not sure if i fully get you, supposing your dates table is like:&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;dates = CALENDAR(DATE(2023, 11, 1), DATE(2024, 2, 5))&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;try to add a calculated column like below:&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;2ndWD = 
VAR _currentdate = [date]
VAR _workdaysinmonth= 
FILTER(
    dates,
    MONTH(dates[date]) = MONTH(_currentdate)
        &amp;amp;&amp;amp;YEAR(dates[date]) = YEAR(_currentdate)
        &amp;amp;&amp;amp;NOT WEEKDAY(dates[date], 2) IN  {6, 7}
)
VAR _firstworkday = MINX(TOPN(1, _workdaysinmonth, [date], ASC), [date])
VAR _secondworkday = MINX(FILTER(_workdaysinmonth, [date]&amp;gt;_firstworkday), [date])
VAR _result = IF(_currentdate = _secondworkday, "yes", "no")
RETURN _result&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;it worked like:&lt;/P&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 22 Nov 2023 05:59:38 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Retrive-Second-Working-Day-in-PowerBI/m-p/3546091#M136345</guid>
      <dc:creator>FreemanZ</dc:creator>
      <dc:date>2023-11-22T05:59:38Z</dc:date>
    </item>
    <item>
      <title>Re: Retrive Second Working Day in PowerBI</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Retrive-Second-Working-Day-in-PowerBI/m-p/3546600#M136376</link>
      <description>&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&lt;SPAN&gt;First you have to&amp;nbsp; add new column and write below dax function, It will work for your requirement.&lt;BR /&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;STRONG&gt;&lt;FONT color="#0000FF"&gt;HOLLIDAY =&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;STRONG&gt;&lt;FONT color="#0000FF"&gt;VAR secweek_num = IF( ROUNDUP(DIVIDE(DAY('calendar'[Date]), 7), 0) IN {2,4} &amp;amp;&amp;amp; WEEKDAY('calendar'[Date]) IN{7,1},"LEAVE", "WORKING DAY")&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;STRONG&gt;&lt;FONT color="#0000FF"&gt;VAR firweek_num = IF( WEEKDAY('calendar'[Date]) = 1, "LEAVE", secweek_num)&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;STRONG&gt;&lt;FONT color="#0000FF"&gt;RETURN&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;STRONG&gt;&lt;FONT color="#0000FF"&gt;firweek_num&lt;BR /&gt;&lt;BR /&gt;&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT color="#000000"&gt;&lt;FONT color="#000000"&gt;Here below i have attached my screen shoot&lt;BR /&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;img /&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;</description>
      <pubDate>Wed, 22 Nov 2023 10:44:51 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Retrive-Second-Working-Day-in-PowerBI/m-p/3546600#M136376</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2023-11-22T10:44:51Z</dc:date>
    </item>
  </channel>
</rss>

