<?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: Return the value for the next succeeding week in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Return-the-value-for-the-next-succeeding-week/m-p/3352963#M125919</link>
    <description>&lt;P&gt;hello if you haev&amp;nbsp; salicer, then you need to add the remove filter on the week 2&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;instead of those you can create a week ID in your calendar table&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;Week ID = 
VAR _min = YEAR(MIN(Calendar[Date]))
RETURN
//Choose WEEKNUM(Calendar[Date],2) for week start on monday or WEEKNUM(Calendar[Date],1) for week start on Sunday//
WEEKNUM(Calendar[Date],2) + (YEAR(Calendar[Date]) - _min) *53&lt;/LI-CODE&gt;&lt;P&gt;&lt;BR /&gt;now insert your filter slicer on the table ltes say you chose the start of week or week nb&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;use the measure&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;Week2DurationHours =
CALCULTAE(SUM('TimeEntry'[DurationHours]),Remove Filters(Date[your slicer]),Date[Week ID] = MAX(Date[Week ID]) - 1)&lt;/LI-CODE&gt;&lt;P&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;</description>
    <pubDate>Thu, 27 Jul 2023 10:01:43 GMT</pubDate>
    <dc:creator>eliasayyy</dc:creator>
    <dc:date>2023-07-27T10:01:43Z</dc:date>
    <item>
      <title>Return the value for the next succeeding week</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Return-the-value-for-the-next-succeeding-week/m-p/3352900#M125916</link>
      <description>&lt;P&gt;Hi guys, I am trying to create a dax measure that will return the value of hours for the succeeding week. I already have the correct dax for Week 1, however I am failing to get the correct value for week 2. Here's what I have so far:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;Week2DurationHours = &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;VAR&lt;/SPAN&gt; &lt;SPAN&gt;SelectedWeekStart&lt;/SPAN&gt;&lt;SPAN&gt; = &lt;/SPAN&gt;&lt;SPAN&gt;SELECTEDVALUE&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;'01_Date'&lt;/SPAN&gt;&lt;SPAN&gt;[Start of Week]&lt;/SPAN&gt;&lt;SPAN&gt;)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;VAR&lt;/SPAN&gt; &lt;SPAN&gt;Week2StartDate&lt;/SPAN&gt;&lt;SPAN&gt; = &lt;/SPAN&gt;&lt;SPAN&gt;CALCULATE&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;MIN&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;'01_Date'&lt;/SPAN&gt;&lt;SPAN&gt;[CalendarDate]&lt;/SPAN&gt;&lt;SPAN&gt;), &lt;/SPAN&gt;&lt;SPAN&gt;'01_Date'&lt;/SPAN&gt;&lt;SPAN&gt;[Start of Week]&lt;/SPAN&gt;&lt;SPAN&gt; = &lt;/SPAN&gt;&lt;SPAN&gt;SelectedWeekStart&lt;/SPAN&gt;&lt;SPAN&gt;) + &lt;/SPAN&gt;&lt;SPAN&gt;7&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;VAR&lt;/SPAN&gt; &lt;SPAN&gt;Week2EndDate&lt;/SPAN&gt;&lt;SPAN&gt; = &lt;/SPAN&gt;&lt;SPAN&gt;Week2StartDate&lt;/SPAN&gt;&lt;SPAN&gt; + &lt;/SPAN&gt;&lt;SPAN&gt;6&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;&amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;CALCULATE&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;SUM&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;'TimeEntry'&lt;/SPAN&gt;&lt;SPAN&gt;[DurationHours]&lt;/SPAN&gt;&lt;SPAN&gt;),&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;'TimeEntry'&lt;/SPAN&gt;&lt;SPAN&gt;[EntryDate]&lt;/SPAN&gt;&lt;SPAN&gt; &amp;gt;= &lt;/SPAN&gt;&lt;SPAN&gt;Week2StartDate&lt;/SPAN&gt;&lt;SPAN&gt; &amp;amp;&amp;amp; &lt;/SPAN&gt;&lt;SPAN&gt;'TimeEntry'&lt;/SPAN&gt;&lt;SPAN&gt;[EntryDate]&lt;/SPAN&gt;&lt;SPAN&gt; &amp;lt;= &lt;/SPAN&gt;&lt;SPAN&gt;Week2EndDate&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; )&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;</description>
      <pubDate>Thu, 27 Jul 2023 09:40:17 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Return-the-value-for-the-next-succeeding-week/m-p/3352900#M125916</guid>
      <dc:creator>ironboy0423</dc:creator>
      <dc:date>2023-07-27T09:40:17Z</dc:date>
    </item>
    <item>
      <title>Re: Return the value for the next succeeding week</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Return-the-value-for-the-next-succeeding-week/m-p/3352963#M125919</link>
      <description>&lt;P&gt;hello if you haev&amp;nbsp; salicer, then you need to add the remove filter on the week 2&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;instead of those you can create a week ID in your calendar table&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;Week ID = 
VAR _min = YEAR(MIN(Calendar[Date]))
RETURN
//Choose WEEKNUM(Calendar[Date],2) for week start on monday or WEEKNUM(Calendar[Date],1) for week start on Sunday//
WEEKNUM(Calendar[Date],2) + (YEAR(Calendar[Date]) - _min) *53&lt;/LI-CODE&gt;&lt;P&gt;&lt;BR /&gt;now insert your filter slicer on the table ltes say you chose the start of week or week nb&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;use the measure&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;Week2DurationHours =
CALCULTAE(SUM('TimeEntry'[DurationHours]),Remove Filters(Date[your slicer]),Date[Week ID] = MAX(Date[Week ID]) - 1)&lt;/LI-CODE&gt;&lt;P&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 27 Jul 2023 10:01:43 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Return-the-value-for-the-next-succeeding-week/m-p/3352963#M125919</guid>
      <dc:creator>eliasayyy</dc:creator>
      <dc:date>2023-07-27T10:01:43Z</dc:date>
    </item>
    <item>
      <title>Re: Return the value for the next succeeding week</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Return-the-value-for-the-next-succeeding-week/m-p/3353056#M125932</link>
      <description>&lt;P&gt;Hello, thanks for this. I think we are close - it only returns incorrect values. Here's the dax so far:&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;Week ID = &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;VAR&lt;/SPAN&gt; &lt;SPAN&gt;_min&lt;/SPAN&gt;&lt;SPAN&gt; = &lt;/SPAN&gt;&lt;SPAN&gt;YEAR&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;MIN&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;'01_Date'&lt;/SPAN&gt;&lt;SPAN&gt;[CalendarDate]&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;WEEKNUM&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;'01_Date'&lt;/SPAN&gt;&lt;SPAN&gt;[CalendarDate]&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;YEAR&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;'01_Date'&lt;/SPAN&gt;&lt;SPAN&gt;[CalendarDate]&lt;/SPAN&gt;&lt;SPAN&gt;) - &lt;/SPAN&gt;&lt;SPAN&gt;_min&lt;/SPAN&gt;&lt;SPAN&gt;) *&lt;/SPAN&gt;&lt;SPAN&gt;53&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;/DIV&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;Week2DurationHours = &lt;/SPAN&gt;&lt;SPAN&gt;CALCULATE&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;SUM&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;'TimeEntry'&lt;/SPAN&gt;&lt;SPAN&gt;[DurationHours]&lt;/SPAN&gt;&lt;SPAN&gt;),&lt;/SPAN&gt;&lt;SPAN&gt;REMOVEFILTERS&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;'01_Date'&lt;/SPAN&gt;&lt;SPAN&gt;[Start of Week]&lt;/SPAN&gt;&lt;SPAN&gt;), &lt;/SPAN&gt;&lt;SPAN&gt;'01_Date'&lt;/SPAN&gt;&lt;SPAN&gt;[Week ID]&lt;/SPAN&gt;&lt;SPAN&gt; = &lt;/SPAN&gt;&lt;SPAN&gt;MAX&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;'01_Date'&lt;/SPAN&gt;&lt;SPAN&gt;[Week ID]&lt;/SPAN&gt;&lt;SPAN&gt;) - &lt;/SPAN&gt;&lt;SPAN&gt;1&lt;/SPAN&gt;&lt;SPAN&gt;)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;</description>
      <pubDate>Thu, 27 Jul 2023 10:59:30 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Return-the-value-for-the-next-succeeding-week/m-p/3353056#M125932</guid>
      <dc:creator>ironboy0423</dc:creator>
      <dc:date>2023-07-27T10:59:30Z</dc:date>
    </item>
    <item>
      <title>Re: Return the value for the next succeeding week</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Return-the-value-for-the-next-succeeding-week/m-p/3354147#M125997</link>
      <description>&lt;P&gt;&lt;SPAN&gt;I'm not sure wich dates covers the returned values, but it is definitely inaccurate so far, may I know your suggestion to this?&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 27 Jul 2023 21:43:42 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Return-the-value-for-the-next-succeeding-week/m-p/3354147#M125997</guid>
      <dc:creator>ironboy0423</dc:creator>
      <dc:date>2023-07-27T21:43:42Z</dc:date>
    </item>
    <item>
      <title>Re: Return the value for the next succeeding week</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Return-the-value-for-the-next-succeeding-week/m-p/3354555#M126014</link>
      <description>&lt;P&gt;Ok did you make week id as a calculated column in your calendar , or measure? It needs to be a calculated column&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;And can you please show me more results as what you are getting ? Are there any other date filters?&amp;nbsp; And i just reaf it again you want the next week not previous week? Then instead of -1&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Week2DurationHours = CALCULATE(SUM('TimeEntry'[DurationHours]),REMOVEFILTERS('01_Date'[Start of Week]), '01_Date'[Week ID] = MAX('01_Date'[Week ID]) + 1)&lt;/P&gt;</description>
      <pubDate>Fri, 28 Jul 2023 04:13:04 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Return-the-value-for-the-next-succeeding-week/m-p/3354555#M126014</guid>
      <dc:creator>eliasayyy</dc:creator>
      <dc:date>2023-07-28T04:13:04Z</dc:date>
    </item>
    <item>
      <title>Re: Return the value for the next succeeding week</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Return-the-value-for-the-next-succeeding-week/m-p/3354635#M126016</link>
      <description>&lt;P&gt;Hello, thanks for your reply. Here's my response:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Ok did you make week id as a calculated column in your calendar , or measure? It needs to be a calculated column - &lt;STRONG&gt;Yup created a calculated in 'Date' table and measure in TimeEntry table.&amp;nbsp;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;And can you please show me more results as what you are getting? -&lt;STRONG&gt; Its just random hours, not sure how to check as they filtered using a slicer.&lt;/STRONG&gt; Are there any other date filters? &lt;STRONG&gt;None&lt;/STRONG&gt; And i just reaf it again you want the next week not previous week? Then instead of -1&amp;nbsp; - &lt;STRONG&gt;Yup, next week please&lt;/STRONG&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 28 Jul 2023 05:07:29 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Return-the-value-for-the-next-succeeding-week/m-p/3354635#M126016</guid>
      <dc:creator>ironboy0423</dc:creator>
      <dc:date>2023-07-28T05:07:29Z</dc:date>
    </item>
    <item>
      <title>Re: Return the value for the next succeeding week</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Return-the-value-for-the-next-succeeding-week/m-p/3354679#M126017</link>
      <description>&lt;P&gt;Thanks again. I update the dax to +1 and it works! thank you so much&lt;/P&gt;</description>
      <pubDate>Fri, 28 Jul 2023 05:35:20 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Return-the-value-for-the-next-succeeding-week/m-p/3354679#M126017</guid>
      <dc:creator>ironboy0423</dc:creator>
      <dc:date>2023-07-28T05:35:20Z</dc:date>
    </item>
    <item>
      <title>Re: Return the value for the next succeeding week</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Return-the-value-for-the-next-succeeding-week/m-p/3354694#M126019</link>
      <description>&lt;P&gt;Glad it worked sorry again for not reading well if you can please accept this post as solultion to help other people know its been solved&lt;/P&gt;</description>
      <pubDate>Fri, 28 Jul 2023 05:53:26 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Return-the-value-for-the-next-succeeding-week/m-p/3354694#M126019</guid>
      <dc:creator>eliasayyy</dc:creator>
      <dc:date>2023-07-28T05:53:26Z</dc:date>
    </item>
    <item>
      <title>Re: Return the value for the next succeeding week</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Return-the-value-for-the-next-succeeding-week/m-p/3371222#M126868</link>
      <description>&lt;P&gt;Hello, sorry for the delay. I notice that our dax for week2duration returns all the sum of a row if there's no succeeding week ahead on a table. How can we fix it please? resharing the dax:&amp;nbsp;&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;ReckonWeek2DurationHours = &lt;/SPAN&gt;&lt;SPAN&gt;CALCULATE&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;SUM&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;'Table1'&lt;/SPAN&gt;&lt;SPAN&gt;[Duration]&lt;/SPAN&gt;&lt;SPAN&gt;), &lt;/SPAN&gt;&lt;SPAN&gt;REMOVEFILTERS&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;'01_Date'&lt;/SPAN&gt;&lt;SPAN&gt;[Start of Week]&lt;/SPAN&gt;&lt;SPAN&gt;), &lt;/SPAN&gt;&lt;SPAN&gt;'01_Date'&lt;/SPAN&gt;&lt;SPAN&gt;[Week ID]&lt;/SPAN&gt;&lt;SPAN&gt; = &lt;/SPAN&gt;&lt;SPAN&gt;MAX&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;'01_Date'&lt;/SPAN&gt;&lt;SPAN&gt;[Week ID]&lt;/SPAN&gt;&lt;SPAN&gt;) + &lt;/SPAN&gt;&lt;SPAN&gt;1&lt;/SPAN&gt;&lt;SPAN&gt;)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 08 Aug 2023 23:59:17 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Return-the-value-for-the-next-succeeding-week/m-p/3371222#M126868</guid>
      <dc:creator>ironboy0423</dc:creator>
      <dc:date>2023-08-08T23:59:17Z</dc:date>
    </item>
  </channel>
</rss>

