cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Thumper369
Frequent Visitor

Need help with List of most recent record update filtered by date and sprint where most recent

Hello Smart Friends.  I need help.  I have spent much time over the last few weeks trying to solve.

 

Situation.

I have a table of data that includes a row of data for every time a story is updated.  I am extracting a list of stories filtered to a given date. So, my intent is to exclude from the page any updates past this date. 

  • I want to know a list of stories that were assigned to a given sprint at of a date.
  • Every story does not have a record on that given date since it may have been assigned to that sprint prior and its “current” assignment is already set.
    • Given that I have to look backward at all history but exclude anything after the given date in case it was updated later
  • I want a list where every ID is represented only once.  So, I would like to include only the last updated record biased on revised date. 

    Here is an example of the data I have.  (Remember some of these ID’s have additional row entries pos the filtered 6/26 date)

 

What I need is a list Filtered fist by Sprint # then by date where the System ID is unique and showing the latest record constrained by the date filter. 

System_IdSystem_TitleSprintIterationNameSystem_RevisedDate
89042Title for story 1 Revision 1Sprint 31Sprint 31 Monkey Fist6/25/2020 5:44
89042Title for story 1 Revision 1Sprint 31Sprint 31 Monkey Fist6/25/2020 5:46
89042Title for story 1 Revision 1Sprint 31Sprint 31 Monkey Fist6/25/2020 5:46
89042Title for story 1 Revision 1Sprint 31Sprint 31 Monkey Fist6/25/2020 6:25
89042Title for story 1 Revision 1Sprint 31Sprint 31 Monkey Fist6/25/2020 7:32
89042Title for story 1 Revision 1Sprint 31Sprint 31 Monkey Fist6/26/2020 5:35
91986Title for story 2 Revision 1Sprint 31Sprint 31 Monkey Fist6/25/2020 13:29
91986Title for story 2 Revision 1Sprint 31Sprint 31 Monkey Fist6/26/2020 7:43
92890Title for story 3 Revision 1Sprint 31Sprint 31 Monkey Fist6/24/2020 10:59
92890Title for story 3 Revision 1Sprint 31Sprint 31 Monkey Fist6/26/2020 7:51
92890Title for story 3 Revision 2Sprint 31Sprint 31 Monkey Fist6/11/2020 9:20
92890Title for story 3 Revision 2Sprint 31Sprint 31 Monkey Fist6/11/2020 10:26
92890Title for story 3 Revision 2Sprint 31Sprint 31 Monkey Fist6/16/2020 10:39
92890Title for story 3 Revision 2Sprint 31Sprint 31 Monkey Fist6/16/2020 10:43
92890Title for story 3 Revision 2Sprint 31Sprint 31 Monkey Fist6/24/2020 8:52
92890Title for story 3 Revision 2Sprint 31Sprint 31 Monkey Fist6/24/2020 9:25
92890Title for story 3 Revision 2Sprint 31Sprint 31 Monkey Fist6/24/2020 10:58
92890Title for story 3 Revision 2Sprint 31Sprint 31 Monkey Fist6/24/2020 10:59
92890Title for story 3 Revision 2Sprint 31Sprint 31 Monkey Fist6/24/2020 10:59
93066Title for story 4 Revision 1Sprint 31Sprint 31 Vader's Taters6/24/2020 11:35
93066Title for story 4 Revision 1Sprint 31Sprint 31 Vader's Taters6/24/2020 14:56
93066Title for story 4 Revision 1Sprint 31Sprint 31 Vader's Taters6/24/2020 20:29
93066Title for story 4 Revision 1Sprint 31Sprint 31 Vader's Taters6/25/2020 8:13
93066Title for story 4 Revision 1Sprint 31Sprint 31 Vader's Taters6/25/2020 11:30
93066Title for story 4 Revision 1Sprint 31Sprint 31 Vader's Taters6/26/2020 17:20
93067Title for story 5 Revision 1Sprint 31Sprint 31 Vader's Taters6/24/2020 11:34
93067Title for story 5 Revision 1Sprint 31Sprint 31 Vader's Taters6/24/2020 20:33
93067Title for story 5 Revision 1Sprint 31Sprint 31 Vader's Taters6/24/2020 21:11
93067Title for story 5 Revision 1Sprint 31Sprint 31 Vader's Taters6/24/2020 21:14
93067Title for story 5 Revision 1Sprint 31Sprint 31 Vader's Taters6/24/2020 21:14
93067Title for story 5 Revision 1Sprint 31Sprint 31 Vader's Taters6/25/2020 7:29
93067Title for story 5 Revision 1Sprint 31Sprint 31 Vader's Taters6/25/2020 11:41
93067Title for story 5 Revision 1Sprint 31Sprint 31 Vader's Taters6/26/2020 17:20


 

5 REPLIES 5
v-alq-msft
Community Support
Community Support

Hi, @Thumper369 

 

Based on your description, I created data to reproduce your scenario. The pbix file is attached in the end.

 

Table:

f1.png

 

Test(a calculated table):

Test = DISTINCT('Table'[System_RevisedDate])

 

You may create a measure as below.

Visual Control = 
var _date = 
CALCULATE(
    MAX('Table'[System_RevisedDate]),
    FILTER(
        ALLSELECTED('Table'),
        'Table'[System_Id] = SELECTEDVALUE('Table'[System_Id])&&
        'Table'[System_RevisedDate]<=SELECTEDVALUE('Test'[System_RevisedDate])
    )
)
return
IF(
    SELECTEDVALUE('Table'[System_RevisedDate])=_date,
    1,0
)

 

Finally you may put the measure in the visual level filter and use the date column from 'Test' table to filter the result.

f3.png

 

Best Regards

Allan

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

 

 

@v-alq-msft  it looks like in  your example shot it shows story 3 twice revision 2 and 3. That is part of the problem I am having.  I want to only see each instacne of ID once.  so in your example I would only want revision 3  

Restating the desired result

 

End result should be a list  of uniquie System_Id (utilizing most recent as defined by System refined date) where filtered by sprint number and <= filtered system date (as to exclude later updates).  

 

Ok, I could still use a solution to this as I will have other things I need that are similar.  


But for me all I needed was setting the change date column to latest and getting rid of the sprint column as power BI was seeing them as two entries that needed to be displayed as one record had one value in it and another had a diferent teams value.  

so it was showing me both records but I did not need that.  I only neede the latest one.  

amitchandak
Super User
Super User

@Thumper369 , Not all requirements are clear to me.

Refer if this can help in getting the last record

LASTNONBLANKVALUE(Table[System_RevisedDate], Count(Table[System_Id]))

or

Sumx(summarize(Table,Table[Sprint],Table[System_Id],"_1",LASTNONBLANKVALUE(Table[System_RevisedDate], Count(Table[System_Id]))),[_1])



Power BI Features || Datamarts: https://youtu.be/8tskWsJTEpg || Field Parameters : https://youtu.be/lqF3Wa1FllE?t=70
Time Intelligence Decoded : https://youtu.be/aU2aKbnHuWs&t=145s
Did I answer your question? Mark my post as a solution! Appreciate your Kudos !! Proud to be a Super User! !!
Dashboard of My Blogs !! Connect on Linkedin !! Subscribe to my youtube Channel !!
Want To Learn Power BI | Beginners !! Advance Concepts !! Power BI For Tableau User !!

Helpful resources

Announcements
August 2022 update 768x460.jpg

Check it Out!

Click here to learn more about the August 2022 updates!

August 1 episode 9_no_dates 768x460.jpg

The Power BI Community Show

Watch the playback when Priya Sathy and Charles Webb discuss Datamarts! Kelly also shares Power BI Community updates.

Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

Top Solution Authors
Top Kudoed Authors