<?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: Fiscal Calendar with Fortnights in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Fiscal-Calendar-with-Fortnights/m-p/3558081#M137029</link>
    <description>&lt;P&gt;Everything went well until the fortnight Number:&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;FORTNIGHT NUM =&lt;/SPAN&gt; &lt;SPAN&gt;CEILING&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;MINX&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;FILTER&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;'Date Table'&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;/SPAN&gt;&lt;SPAN&gt;'Date Table'&lt;/SPAN&gt;&lt;SPAN&gt;[Date]&lt;/SPAN&gt;&lt;SPAN&gt; &amp;lt;= &lt;/SPAN&gt;&lt;SPAN&gt;EARLIER&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;'Date Table'&lt;/SPAN&gt;&lt;SPAN&gt;[Date]&lt;/SPAN&gt;&lt;SPAN&gt;)),&lt;/SPAN&gt;&lt;SPAN&gt;'Date Table'&lt;/SPAN&gt;&lt;SPAN&gt;[Date]&lt;/SPAN&gt;&lt;SPAN&gt;), &lt;/SPAN&gt;&lt;SPAN&gt;14&lt;/SPAN&gt;&lt;SPAN&gt;)/&lt;/SPAN&gt;&lt;SPAN&gt;14&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;then:&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;FISCAL YEAR FN =&lt;/SPAN&gt; &lt;SPAN&gt;'Date Table'&lt;/SPAN&gt;&lt;SPAN&gt;[FISC YEAR]&lt;/SPAN&gt;&lt;SPAN&gt; &amp;amp; &lt;/SPAN&gt;&lt;SPAN&gt;" FN"&lt;/SPAN&gt;&lt;SPAN&gt; &amp;amp; &lt;/SPAN&gt;&lt;SPAN&gt;FORMAT&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;'Date Table'&lt;/SPAN&gt;&lt;SPAN&gt;[FORTNIGHT NUM]&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;"01"&lt;/SPAN&gt;&lt;SPAN&gt;)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&lt;SPAN&gt;Column is:&amp;nbsp;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;img /&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;What did I do wrong??&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;/DIV&gt;&lt;/DIV&gt;</description>
    <pubDate>Wed, 29 Nov 2023 07:23:01 GMT</pubDate>
    <dc:creator>CharnanK</dc:creator>
    <dc:date>2023-11-29T07:23:01Z</dc:date>
    <item>
      <title>Fiscal Calendar with Fortnights</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Fiscal-Calendar-with-Fortnights/m-p/3558023#M137026</link>
      <description>&lt;P&gt;I have created a Fiscal Calendar, but I need to add in Fortnights. 1/7/2023 - 14/7/2023 as FN01 etc for 2023 Fiscal Year.&lt;/P&gt;&lt;P&gt;How to I do this?&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 29 Nov 2023 06:37:20 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Fiscal-Calendar-with-Fortnights/m-p/3558023#M137026</guid>
      <dc:creator>CharnanK</dc:creator>
      <dc:date>2023-11-29T06:37:20Z</dc:date>
    </item>
    <item>
      <title>Re: Fiscal Calendar with Fortnights</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Fiscal-Calendar-with-Fortnights/m-p/3558027#M137027</link>
      <description>&lt;P&gt;In Power BI, you can create a Fiscal Calendar with Fortnights by following these general steps. Keep in mind that the specifics might vary based on your exact requirements and the structure of your data. I'll provide a high-level guide:&lt;/P&gt;&lt;OL&gt;&lt;LI&gt;&lt;P&gt;&lt;STRONG&gt;Create a Date Table:&lt;/STRONG&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;In Power BI, it's common to create a separate Date table that includes all the dates you need for your analysis.&lt;/LI&gt;&lt;/UL&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;&lt;STRONG&gt;Add a Fiscal Year Column:&lt;/STRONG&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;Create a column that assigns each date to a fiscal year. This could involve mapping each date to the corresponding fiscal year based on your organization's fiscal calendar.&lt;/LI&gt;&lt;/UL&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;&lt;STRONG&gt;Calculate Fortnights:&lt;/STRONG&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;You can create a new column to calculate the fortnight for each date. For example, you can use a formula like this:&lt;/LI&gt;&lt;/UL&gt;&lt;/LI&gt;&lt;/OL&gt;&lt;P&gt;Fortnight = CEILING(MINX(FILTER('DateTable', 'DateTable'[Date] &amp;lt;= EARLIER('DateTable'[Date])), 'DateTable'[Date]),14)/14&lt;/P&gt;&lt;OL&gt;&lt;LI&gt;&lt;UL&gt;&lt;LI&gt;This formula uses the CEILING function to round up the date to the nearest multiple of 14, effectively grouping dates into fortnights.&lt;/LI&gt;&lt;/UL&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;&lt;STRONG&gt;Combine Fiscal Year and Fortnight:&lt;/STRONG&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;Create a new column that combines the fiscal year and fortnight. For example:&lt;/LI&gt;&lt;/UL&gt;&lt;/LI&gt;&lt;/OL&gt;&lt;P&gt;FiscalYearFortnight = 'DateTable'[FiscalYear] &amp;amp; " FN" &amp;amp; FORMAT('DateTable'[Fortnight], "00")&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;OL&gt;&lt;LI&gt;&lt;P&gt;&lt;STRONG&gt;Use the New Column in Visuals:&lt;/STRONG&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;Now, you can use the FiscalYearFortnight column in your visuals to analyze data by fiscal year and fortnight.&lt;/LI&gt;&lt;/UL&gt;&lt;/LI&gt;&lt;/OL&gt;&lt;P&gt;Remember that the exact implementation might depend on your specific fiscal calendar and the structure of your existing data. Adjust the formulas and column names according to your needs.&lt;/P&gt;&lt;P&gt;If you encounter any issues or have specific requirements, feel free to provide more details for further assistance.&lt;/P&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class=""&gt;&amp;nbsp;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&amp;nbsp;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 29 Nov 2023 06:39:25 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Fiscal-Calendar-with-Fortnights/m-p/3558027#M137027</guid>
      <dc:creator>123abc</dc:creator>
      <dc:date>2023-11-29T06:39:25Z</dc:date>
    </item>
    <item>
      <title>Re: Fiscal Calendar with Fortnights</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Fiscal-Calendar-with-Fortnights/m-p/3558081#M137029</link>
      <description>&lt;P&gt;Everything went well until the fortnight Number:&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;FORTNIGHT NUM =&lt;/SPAN&gt; &lt;SPAN&gt;CEILING&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;MINX&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;FILTER&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;'Date Table'&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;/SPAN&gt;&lt;SPAN&gt;'Date Table'&lt;/SPAN&gt;&lt;SPAN&gt;[Date]&lt;/SPAN&gt;&lt;SPAN&gt; &amp;lt;= &lt;/SPAN&gt;&lt;SPAN&gt;EARLIER&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;'Date Table'&lt;/SPAN&gt;&lt;SPAN&gt;[Date]&lt;/SPAN&gt;&lt;SPAN&gt;)),&lt;/SPAN&gt;&lt;SPAN&gt;'Date Table'&lt;/SPAN&gt;&lt;SPAN&gt;[Date]&lt;/SPAN&gt;&lt;SPAN&gt;), &lt;/SPAN&gt;&lt;SPAN&gt;14&lt;/SPAN&gt;&lt;SPAN&gt;)/&lt;/SPAN&gt;&lt;SPAN&gt;14&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;then:&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;FISCAL YEAR FN =&lt;/SPAN&gt; &lt;SPAN&gt;'Date Table'&lt;/SPAN&gt;&lt;SPAN&gt;[FISC YEAR]&lt;/SPAN&gt;&lt;SPAN&gt; &amp;amp; &lt;/SPAN&gt;&lt;SPAN&gt;" FN"&lt;/SPAN&gt;&lt;SPAN&gt; &amp;amp; &lt;/SPAN&gt;&lt;SPAN&gt;FORMAT&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;'Date Table'&lt;/SPAN&gt;&lt;SPAN&gt;[FORTNIGHT NUM]&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;"01"&lt;/SPAN&gt;&lt;SPAN&gt;)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&lt;SPAN&gt;Column is:&amp;nbsp;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;img /&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;What did I do wrong??&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;/DIV&gt;&lt;/DIV&gt;</description>
      <pubDate>Wed, 29 Nov 2023 07:23:01 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Fiscal-Calendar-with-Fortnights/m-p/3558081#M137029</guid>
      <dc:creator>CharnanK</dc:creator>
      <dc:date>2023-11-29T07:23:01Z</dc:date>
    </item>
    <item>
      <title>Re: Fiscal Calendar with Fortnights</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Fiscal-Calendar-with-Fortnights/m-p/3558117#M137037</link>
      <description>&lt;P&gt;It seems like the issue might be related to how the fortnight number is calculated. The formula you provided uses the MINX and FILTER functions to find the minimum date up to the current date and then calculates the fortnight number using the CEILING function.&lt;/P&gt;&lt;P&gt;However, there's a simpler way to calculate the fortnight number without using MINX and FILTER. You can use the ROUNDUP function directly on the day of the year to get the fortnight number. Here's an updated formula:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;FORTNIGHT NUM = ROUNDUP(DAY('Date Table'[Date])/14, 0)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;And then, for your 'FISCAL YEAR FN' column:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;FISCAL YEAR FN = 'Date Table'[FISC YEAR] &amp;amp; " FN" &amp;amp; FORMAT('Date Table'[FORTNIGHT NUM], "00")&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This formula divides the day of the year by 14 and rounds up to the nearest whole number, giving you the fortnight number. The FORMAT function is then used to ensure that the fortnight number is displayed with leading zeros.&lt;/P&gt;&lt;P&gt;Try using this formula and see if it resolves the issue you're facing. If you encounter any further problems, please provide more details on the specific error or unexpected result you're getting.&lt;/P&gt;</description>
      <pubDate>Wed, 29 Nov 2023 07:48:05 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Fiscal-Calendar-with-Fortnights/m-p/3558117#M137037</guid>
      <dc:creator>123abc</dc:creator>
      <dc:date>2023-11-29T07:48:05Z</dc:date>
    </item>
    <item>
      <title>Re: Fiscal Calendar with Fortnights</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Fiscal-Calendar-with-Fortnights/m-p/3558128#M137041</link>
      <description>&lt;P&gt;Works better - but it is doing FN01 FN02 FN03 (July) then August comes and it is going FN01 FN02 FN03 again - almost there - so close!!!&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 29 Nov 2023 07:54:13 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Fiscal-Calendar-with-Fortnights/m-p/3558128#M137041</guid>
      <dc:creator>CharnanK</dc:creator>
      <dc:date>2023-11-29T07:54:13Z</dc:date>
    </item>
    <item>
      <title>Re: Fiscal Calendar with Fortnights</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Fiscal-Calendar-with-Fortnights/m-p/3558155#M137044</link>
      <description>&lt;P&gt;I think it is with this formula&amp;nbsp;&lt;SPAN&gt;FORTNIGHT NUM = ROUNDUP(DAY('Date Table'[Date])/14, 0) as it is in that column that the error is - on 31/7 it reverts from 3 back to 1 on 1/8&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 29 Nov 2023 08:01:11 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Fiscal-Calendar-with-Fortnights/m-p/3558155#M137044</guid>
      <dc:creator>CharnanK</dc:creator>
      <dc:date>2023-11-29T08:01:11Z</dc:date>
    </item>
    <item>
      <title>Re: Fiscal Calendar with Fortnights</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Fiscal-Calendar-with-Fortnights/m-p/3558171#M137047</link>
      <description>&lt;P&gt;&lt;SPAN&gt;It seems like the issue is related to the transition between fiscal years. To address this, you can modify the FortnightNum calculation to consider the fiscal year transition. Here's an updated version:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;FortnightNum =&lt;BR /&gt;VAR StartDate = DATE(YEAR('Date Table'[Date]), 1, 1)&lt;BR /&gt;VAR DaysFromStart = 'Date Table'[Date] - StartDate&lt;BR /&gt;VAR FortnightOffset = IF(DaysFromStart &amp;gt;= 0, 0, 1)&lt;BR /&gt;RETURN&lt;BR /&gt;INT((DAY('Date Table'[Date]) - 1 + FortnightOffset) / 14) + 1&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This modification introduces the FortnightOffset variable, which adjusts the calculation based on whether the date is in the current fiscal year or the next fiscal year. This should prevent the FortnightNum from resetting to FN01 in August.&lt;/P&gt;&lt;P&gt;Update the 'FiscalYearFN' formula accordingly:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;FiscalYearFN = 'Date Table'[FISC YEAR] &amp;amp; " FN" &amp;amp; FORMAT('Date Table'[FortnightNum], "00")&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Make sure to replace 'Date Table' with the actual name of your date table.&lt;/P&gt;&lt;P&gt;This modification ensures that the fortnight number continues to increment throughout the fiscal year without resetting when transitioning to a new calendar year.&lt;/P&gt;</description>
      <pubDate>Wed, 29 Nov 2023 08:04:20 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Fiscal-Calendar-with-Fortnights/m-p/3558171#M137047</guid>
      <dc:creator>123abc</dc:creator>
      <dc:date>2023-11-29T08:04:20Z</dc:date>
    </item>
    <item>
      <title>Re: Fiscal Calendar with Fortnights</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Fiscal-Calendar-with-Fortnights/m-p/3558175#M137048</link>
      <description>&lt;P&gt;&lt;SPAN&gt;I see, the issue seems to be related to the way the fortnight number is calculated, especially when transitioning between months. Let's adjust the FortnightNum calculation to handle this scenario better:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;FortnightNum =&lt;BR /&gt;VAR StartDate = DATE(YEAR('Date Table'[Date]), 1, 1)&lt;BR /&gt;VAR DaysFromStart = 'Date Table'[Date] - StartDate&lt;BR /&gt;VAR FortnightOffset = IF(DaysFromStart &amp;gt;= 0, 0, 1)&lt;BR /&gt;RETURN&lt;BR /&gt;ROUNDUP(DaysFromStart / 14, 0) + FortnightOffset&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This modification incorporates the FortnightOffset variable to adjust for the transition between fiscal years. It rounds up based on the number of days from the start of the fiscal year.&lt;/P&gt;&lt;P&gt;Update the 'FiscalYearFN' formula accordingly:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;FiscalYearFN = 'Date Table'[FISC YEAR] &amp;amp; " FN" &amp;amp; FORMAT('Date Table'[FortnightNum], "00")&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Please replace 'Date Table' with the actual name of your date table.&lt;/P&gt;&lt;P&gt;This adjustment should help in maintaining the continuity of fortnight numbers across the fiscal year transition.&lt;/P&gt;</description>
      <pubDate>Wed, 29 Nov 2023 08:05:16 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Fiscal-Calendar-with-Fortnights/m-p/3558175#M137048</guid>
      <dc:creator>123abc</dc:creator>
      <dc:date>2023-11-29T08:05:16Z</dc:date>
    </item>
    <item>
      <title>Re: Fiscal Calendar with Fortnights</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Fiscal-Calendar-with-Fortnights/m-p/3558197#M137051</link>
      <description>&lt;P&gt;OK it is now working it - THANKYOU!!!!! One last question - my fortnights start on a Saturday - any ideas?&amp;nbsp; Thankyou so much - really stumped with this one&lt;/P&gt;</description>
      <pubDate>Wed, 29 Nov 2023 08:28:25 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Fiscal-Calendar-with-Fortnights/m-p/3558197#M137051</guid>
      <dc:creator>CharnanK</dc:creator>
      <dc:date>2023-11-29T08:28:25Z</dc:date>
    </item>
    <item>
      <title>Re: Fiscal Calendar with Fortnights</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Fiscal-Calendar-with-Fortnights/m-p/3558237#M137057</link>
      <description>&lt;P&gt;&lt;SPAN&gt;I'm glad to hear that it's working! If your fortnights start on a Saturday and you want to align your fortnight calculation with that, you can adjust the formula accordingly. Assuming that your fiscal year always starts on July 1, and the first day of the fiscal year is a Saturday, you can modify the formula like this:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;FORTNIGHT NUM =&lt;BR /&gt;VAR FiscalYearStart = DATE(YEAR('Date Table'[Date]), 7, 1)&lt;BR /&gt;VAR DaysSinceStart = 'Date Table'[Date] - FiscalYearStart&lt;BR /&gt;VAR DaysOffset = MOD(DaysSinceStart, 7) // Calculate the number of days since the start of the fiscal year and find the offset from the first Saturday&lt;BR /&gt;RETURN&lt;BR /&gt;ROUNDUP((DaysSinceStart - DaysOffset + 1) / 14, 0)&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This adjustment uses the MOD function to find the offset from the first Saturday in the fiscal year. This way, your fortnight count will start from the first Saturday and continue every 14 days.&lt;/P&gt;&lt;P&gt;Please replace 'Date Table' with your actual table name if it's different. Adjust the fiscal year start date in the FiscalYearStart variable if your fiscal year starts on a different date.&lt;/P&gt;&lt;P&gt;This modification should align your fortnight calculation with Saturdays at the start of each fortnight.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&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>Wed, 29 Nov 2023 08:33:54 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Fiscal-Calendar-with-Fortnights/m-p/3558237#M137057</guid>
      <dc:creator>123abc</dc:creator>
      <dc:date>2023-11-29T08:33:54Z</dc:date>
    </item>
    <item>
      <title>Re: Fiscal Calendar with Fortnights</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Fiscal-Calendar-with-Fortnights/m-p/3558246#M137061</link>
      <description>&lt;P&gt;OK - got excited too soon .......... worked perfectly, except 01/01/2024 now becomes FN -13 and it works backward &lt;span class="lia-unicode-emoji" title=":disappointed_face:"&gt;😞&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 29 Nov 2023 08:37:25 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Fiscal-Calendar-with-Fortnights/m-p/3558246#M137061</guid>
      <dc:creator>CharnanK</dc:creator>
      <dc:date>2023-11-29T08:37:25Z</dc:date>
    </item>
    <item>
      <title>Re: Fiscal Calendar with Fortnights</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Fiscal-Calendar-with-Fortnights/m-p/3558256#M137062</link>
      <description>&lt;P&gt;&lt;SPAN&gt;I see. It seems that the current formula is not handling the negative values for fortnights as expected. Let's adjust the formula to ensure it works correctly for the entire fiscal year. Here's an updated version:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;FORTNIGHT NUM =&lt;BR /&gt;VAR FiscalYearStart = CALCULATE(MIN('Date Table'[Date]), ALL('Date Table'))&lt;BR /&gt;VAR DaysSinceStart = DATEDIFF(FiscalYearStart, 'Date Table'[Date], DAY)&lt;BR /&gt;VAR FortnightNumber = CEILING((DaysSinceStart + WEEKDAY(FiscalYearStart) - 1) / 14, 1)&lt;BR /&gt;RETURN&lt;BR /&gt;IF(FortnightNumber &amp;lt;= 0, FortnightNumber + CEILING(DAY(FiscalYearStart) / 14, 1), FortnightNumber)&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This modification includes an IF statement to handle cases where the calculated Fortnight Number is less than or equal to 0. In such cases, it adjusts the Fortnight Number to ensure it starts counting from the first fortnight.&lt;/P&gt;&lt;P&gt;Please replace 'Date Table'[Date] with your actual date column reference.&lt;/P&gt;&lt;P&gt;Give this adjustment a try, and it should address the issue of negative Fortnight Numbers. Let me know if you encounter any further issues or if you have additional questions!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&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>Wed, 29 Nov 2023 08:41:38 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Fiscal-Calendar-with-Fortnights/m-p/3558256#M137062</guid>
      <dc:creator>123abc</dc:creator>
      <dc:date>2023-11-29T08:41:38Z</dc:date>
    </item>
    <item>
      <title>Re: Fiscal Calendar with Fortnights</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Fiscal-Calendar-with-Fortnights/m-p/3558263#M137064</link>
      <description>&lt;P&gt;Thankyou - so the Fortnight Num is 1 from 1/7/2023 - 9/7/23 (whereas it should be to 14/7/23 - must be something in this formula as it was correct last step&lt;/P&gt;</description>
      <pubDate>Wed, 29 Nov 2023 08:46:43 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Fiscal-Calendar-with-Fortnights/m-p/3558263#M137064</guid>
      <dc:creator>CharnanK</dc:creator>
      <dc:date>2023-11-29T08:46:43Z</dc:date>
    </item>
    <item>
      <title>Re: Fiscal Calendar with Fortnights</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Fiscal-Calendar-with-Fortnights/m-p/3558367#M137070</link>
      <description>&lt;P&gt;&lt;SPAN&gt;Let's refine the formula to ensure that the fortnight numbering aligns correctly with your requirements. Specifically, the issue seems to be related to how the adjustment is handled for the start date of the fiscal year.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;FORTNIGHT NUM =&lt;BR /&gt;VAR FiscalYearStart = DATE(YEAR('Date Table'[Date]), 7, 1)&lt;BR /&gt;VAR DaysElapsed = 'Date Table'[Date] - FiscalYearStart&lt;BR /&gt;VAR DaysToAdd = MOD(7 - WEEKDAY(FiscalYearStart, 2) + 1, 7) // Days to add to align with the start day&lt;/P&gt;&lt;P&gt;// Ensure the start date is treated as FN01&lt;BR /&gt;VAR AdjustedDaysElapsed = IF(DaysElapsed &amp;lt; 0, 0, DaysElapsed)&lt;/P&gt;&lt;P&gt;RETURN&lt;BR /&gt;ROUNDUP((AdjustedDaysElapsed + DaysToAdd) / 14, 0)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This formula calculates the adjusted days elapsed, ensuring that the start date of the fiscal year is considered FN01. Please replace your existing FORTNIGHT NUM column with this updated formula and test it across various dates, including the start date of the fiscal year.&lt;/P&gt;&lt;P&gt;I appreciate your patience, and I hope this refinement resolves the issue. If you encounter any further challenges or have additional questions, feel free to let me know!&lt;/P&gt;</description>
      <pubDate>Wed, 29 Nov 2023 09:20:37 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Fiscal-Calendar-with-Fortnights/m-p/3558367#M137070</guid>
      <dc:creator>123abc</dc:creator>
      <dc:date>2023-11-29T09:20:37Z</dc:date>
    </item>
    <item>
      <title>Re: Fiscal Calendar with Fortnights</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Fiscal-Calendar-with-Fortnights/m-p/3558379#M137072</link>
      <description>&lt;P&gt;Almost - I just had to change the Fiscal Year Start from , 2 to ,1)&amp;nbsp; BUT when i gets to 01/01/2024 it goes to FN00 &lt;span class="lia-unicode-emoji" title=":disappointed_face:"&gt;😞&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 29 Nov 2023 09:25:43 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Fiscal-Calendar-with-Fortnights/m-p/3558379#M137072</guid>
      <dc:creator>CharnanK</dc:creator>
      <dc:date>2023-11-29T09:25:43Z</dc:date>
    </item>
    <item>
      <title>Re: Fiscal Calendar with Fortnights</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Fiscal-Calendar-with-Fortnights/m-p/3558434#M137077</link>
      <description>&lt;P&gt;I think this will solve your issue:&lt;/P&gt;&lt;PRE&gt;Fortnight = 
VAR __BaseDate = DATE (2019,1,1)
VAR __Days = ([Value]. [Date] - __BaseDate) * 1
RETURN
    "FN" &amp;amp; 
    FORMAT (
        INT ( __Days / 14 ) + 1,
        "00"
    )&lt;/PRE&gt;&lt;P&gt;This code will group dates into fortnights starting from January 1, 2019. You can modify the code to suit your specific requirements.&lt;/P&gt;&lt;P&gt;To add fortnights to your Fiscal Calendar in Power BI, you can create a calculated column using the above DAX code. You can also create a custom fiscal calendar in Power BI by following the steps outlined in this&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;A href="https://www.brunner.bi/post/creating-a-custom-fiscal-calendar-in-power-bi" target="_blank" rel="noopener"&gt;tutorial&lt;/A&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;by Brunner BI.&lt;/P&gt;&lt;P&gt;I hope this helps!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&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;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 29 Nov 2023 09:42:22 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Fiscal-Calendar-with-Fortnights/m-p/3558434#M137077</guid>
      <dc:creator>123abc</dc:creator>
      <dc:date>2023-11-29T09:42:22Z</dc:date>
    </item>
    <item>
      <title>Re: Fiscal Calendar with Fortnights</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Fiscal-Calendar-with-Fortnights/m-p/3558578#M137088</link>
      <description>&lt;P&gt;Sorry confused as to the [value] - what would that be referring to&lt;/P&gt;</description>
      <pubDate>Wed, 29 Nov 2023 10:35:48 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Fiscal-Calendar-with-Fortnights/m-p/3558578#M137088</guid>
      <dc:creator>CharnanK</dc:creator>
      <dc:date>2023-11-29T10:35:48Z</dc:date>
    </item>
    <item>
      <title>Re: Fiscal Calendar with Fortnights</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Fiscal-Calendar-with-Fortnights/m-p/3558604#M137091</link>
      <description>&lt;P&gt;I apologize for the confusion. The&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;[value]&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;in the formula is a placeholder for the column name that contains the dates you want to use to calculate the fortnight number. You should replace&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;[value]&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;with the actual name of the column.&lt;/P&gt;&lt;P&gt;For example, if your date column is named&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;Date, the formula would be:&lt;/P&gt;&lt;PRE&gt;FORTNIGHT NUM = 
VAR __BaseDate = DATE (2023, 1, 6) // January 6, 2023 is a Saturday
VAR __Days = ([Date] - __BaseDate) * 1
VAR __Month = MONTH([Date])
VAR __DayOfWeek = WEEKDAY([Date], 2) // 1 is Monday, 2 is Tuesday, ..., 7 is Sunday
VAR __Offset = IF(__DayOfWeek &amp;gt;= 6, 1, 0)
RETURN
    "FN" &amp;amp; FORMAT(__Month * 2 - __Offset + CEILING((__Days - __Offset) / 14, 1), "00")&lt;/PRE&gt;&lt;P&gt;I hope this clears things up. Let me know if you have any other questions.&lt;/P&gt;</description>
      <pubDate>Wed, 29 Nov 2023 10:43:28 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Fiscal-Calendar-with-Fortnights/m-p/3558604#M137091</guid>
      <dc:creator>123abc</dc:creator>
      <dc:date>2023-11-29T10:43:28Z</dc:date>
    </item>
    <item>
      <title>Re: Fiscal Calendar with Fortnights</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Fiscal-Calendar-with-Fortnights/m-p/3558665#M137093</link>
      <description>&lt;P&gt;I worked it - changed your original measure - and it's perfect - thankyou for your help&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Final measure:&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;FortnightNum =&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;VAR&lt;/SPAN&gt; &lt;SPAN&gt;StartDate&lt;/SPAN&gt;&lt;SPAN&gt; = &lt;/SPAN&gt;&lt;SPAN&gt;DATE&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;2023&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;7&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;1&lt;/SPAN&gt;&lt;SPAN&gt;) - &lt;/SPAN&gt;&lt;SPAN&gt;WEEKDAY&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;DATE&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;2023&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;/SPAN&gt;&lt;SPAN&gt;7&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;/SPAN&gt;&lt;SPAN&gt;1&lt;/SPAN&gt;&lt;SPAN&gt;),&lt;/SPAN&gt;&lt;SPAN&gt;2&lt;/SPAN&gt;&lt;SPAN&gt;) +&lt;/SPAN&gt;&lt;SPAN&gt;5&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;VAR&lt;/SPAN&gt; &lt;SPAN&gt;CurrentDate&lt;/SPAN&gt;&lt;SPAN&gt; = &lt;/SPAN&gt;&lt;SPAN&gt;'date table'&lt;/SPAN&gt;&lt;SPAN&gt;[Date]&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;VAR&lt;/SPAN&gt; &lt;SPAN&gt;DaysElapsed&lt;/SPAN&gt;&lt;SPAN&gt; = &lt;/SPAN&gt;&lt;SPAN&gt;CurrentDate&lt;/SPAN&gt;&lt;SPAN&gt; - &lt;/SPAN&gt;&lt;SPAN&gt;StartDate&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;VAR&lt;/SPAN&gt; &lt;SPAN&gt;FortnightNum&lt;/SPAN&gt;&lt;SPAN&gt; = &lt;/SPAN&gt;&lt;SPAN&gt;IF&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;DaysElapsed&lt;/SPAN&gt;&lt;SPAN&gt; &amp;gt;= &lt;/SPAN&gt;&lt;SPAN&gt;364&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;1&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;ROUNDUP&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;DaysElapsed&lt;/SPAN&gt;&lt;SPAN&gt; / &lt;/SPAN&gt;&lt;SPAN&gt;14&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;0&lt;/SPAN&gt;&lt;SPAN&gt;))&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;RETURN&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;"FN"&lt;/SPAN&gt;&lt;SPAN&gt; &amp;amp; &lt;/SPAN&gt;&lt;SPAN&gt;FORMAT&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;FortnightNum&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;"00"&lt;/SPAN&gt;&lt;SPAN&gt;)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;This now continues right through and restarts for the next fiscal year as well.&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;Appreciate your help&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;</description>
      <pubDate>Wed, 29 Nov 2023 11:17:35 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Fiscal-Calendar-with-Fortnights/m-p/3558665#M137093</guid>
      <dc:creator>CharnanK</dc:creator>
      <dc:date>2023-11-29T11:17:35Z</dc:date>
    </item>
  </channel>
</rss>

