+ Reply to Thread
Results 1 to 62 of 62

Returning highest milestone for ID with INDEX?

  1. #1
    Registered User
    Join Date
    06-30-2021
    Location
    Germany
    MS-Off Ver
    Office 365
    Posts
    27

    Returning highest milestone for ID with INDEX?

    Hello everybody,

    I have the problem that I would like to find the highest Milestone for a given ID in a table, in order to display this information in a dashboard.

    To do that I am trying to unse an INDEX-formula: =WENN(INDEX($C$7:$D$11;VERGLEICH(G7;$C$7:$C$11;0);2)="M3";"MS3";WENN(INDEX($C$7:$D$11;VERGLEICH(G7;$C$7:$C$11;0);2)="MS2";"MS2";WENN(INDEX($C$7:$D$11;VERGLEICH(G7;$C$7:$C$11;0);2)="MS1";"MS1";"Error")))

    With the help of the INDEX function I am trying to find the highest match for a partner ID in the given table. However the INDEX function always seems to give out the value where one of the milestones are matched. Cell by cell the formula is checking for all the milestones until one matches.

    Is there a better way to approach this? I have attached a sample of the excel sheet.

    Thanks in advance
    Felix

    Unbenannt.PNG
    Attached Files Attached Files

  2. #2
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,129

    Re: Returning highest milestone for ID with INDEX?

    Please update your profile to show your Excel version, as xx doesn't tell us anything helpful!!

    Maybe this:


    ="MS"&MAX(IF($C$4:$C$8=G4,RIGHT($D$4:$D$8,1)+0))

    IF you are using Excel 365, enter is required. However, if you are using an earlier version, you will need to enter it as an array formula.

    These are a little different from ordinary formulae in that they MUST be confirmed in the FIRST CELL ONLY by pressing CTRL+SHIFT+ENTER to activate the array, not just ENTER. After that, the array can be dragged down as normal, to cover the desired range.

    You will know the array is active when you see the curly brackets { } appear around the outside of your formula. If you do not use CTRL+SHIFT+ENTER you will (almost always) get an error message or an incorrect answer. Press F2 on that cell and try again.

    Don't type the curly brackets yourself - it won't work...

    In D, you may also need ot use ; instead of ,
    Attached Files Attached Files
    Glenn




    None of us get paid for helping you... we do this for fun. So DON'T FORGET to say "Thank You" to all who have freely given some of their time to help YOU

  3. #3
    Registered User
    Join Date
    06-30-2021
    Location
    Germany
    MS-Off Ver
    Office 365
    Posts
    27

    Re: Returning highest milestone for ID with INDEX?

    Dear Glenn,

    absolutely amazing, your solution works much better than my suggestion (and is so much simpler).

    My bad, I am using Office 365.

    The situation however did get a little bit more complicated.

    The Milestone 9 (MS9) shows that a process related the an ID went on hold. However if there is still a process available for the SAME ID which is in MS1, MS2, MS3, then I still need to display the lower values in the dashboard. Is there a way to limit the MAX-formula from MS1-MS6, and in the second round check for MS9? It also would be OK to change the label of MS9 into "on hold", however then the MAX-formula again does not seem to cope anymore.

    Much thanks in advance (once again).

    Best regards
    Felix

  4. #4
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,129

    Re: Returning highest milestone for ID with INDEX?

    I'll look at this again in the morning. Beer time now. However, do take a moment to update your profile to show O365 as your current version.

    AND... post an Excel sheet to SHOW me what you mean.

  5. #5
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,129

    Re: Returning highest milestone for ID with INDEX?

    Also... if your MS numbers can become greater than 9... (i.e. 2+ digits) include those in your revised sample.

  6. #6
    Registered User
    Join Date
    06-30-2021
    Location
    Germany
    MS-Off Ver
    Office 365
    Posts
    27

    Re: Returning highest milestone for ID with INDEX?

    Dear Glenn,

    done, now it should display my version on the profile. Hope you have enjoyed your beer!

    Attached you find a sample for what I am looking for. In general I have a process made up of different milestones, that solutions are going through. Solutions can be assessed multiple times, thus per unique solution (marked with solution-ID) I can have multiple milestones.

    If a solution has failed to quality, it gets the Milestone MS9 - Solution on hold. However if for the same solution-ID there is still an evaluation process ongoing, I want to overwrite MS9 and show the next highest status.

    I hope this somehow explains what I am looking for.

    I really appreciate your help!!

    Best regards
    Felix

  7. #7
    Registered User
    Join Date
    06-30-2021
    Location
    Germany
    MS-Off Ver
    Office 365
    Posts
    27

    Re: Returning highest milestone for ID with INDEX?

    And forgot to mention: yes, MS9 can also be replaced with a two-digit number.

  8. #8
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,129

    Re: Returning highest milestone for ID with INDEX?

    I suspect that this STILL is incorrect... as you did not explain the significance of MS10, MS11, etc....


    ="MS"&MIN(IFERROR(AGGREGATE(14,6,SUBSTITUTE($D$4:$D$11,"MS","")+0/($C$4:$C$11=$G4),{1,2}),10^10))

    If this is incorrect, please update your sheet with a FULLY representative sample.

  9. #9
    Registered User
    Join Date
    06-30-2021
    Location
    Germany
    MS-Off Ver
    Office 365
    Posts
    27

    Re: Returning highest milestone for ID with INDEX?

    Currently MS10, MS11, ... are not used, thus it might be easier to change MS9 to a double digit value? (i.e. MS10)?

    The current solution looks almost fully correct, however if I change for the Solution-ID 2 the MS9 into MS4, the Dashboard does not update to MS4 (then new highest milestone) but keeps displaying MS9.

  10. #10
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,129

    Re: Returning highest milestone for ID with INDEX?

    Mmm. One more go...

    =LET(a,SUBSTITUTE($D$4:$D$11,"MS",""),b,($C$4:$C$11=$G4),"MS"&MAX(IFERROR(AGGREGATE(IF(AGGREGATE(14,6,a/b,1)=9,15,14),6,a/b,{1,2}),1/10^10)))

  11. #11
    Registered User
    Join Date
    06-30-2021
    Location
    Germany
    MS-Off Ver
    Office 365
    Posts
    27

    Re: Returning highest milestone for ID with INDEX?

    Hi Glenn,

    for some reason I get an error with your formula. And I have a hard time following the formula in the first place :D.

    Attachment 738729

  12. #12
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,129

    Re: Returning highest milestone for ID with INDEX?

    Microsoft version incompatability! Your version of Excel 365 obviously doesn't support LET. I am away from my PC for about an hour. I'll fix it then.

  13. #13
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,129

    Re: Returning highest milestone for ID with INDEX?

    According to Microsoft, LET is available in Excel for Microsoft 365, Excel for Microsoft 365 for Mac & Excel for the web. No idea why it's not working for you!!

    =IF(G4="","","MS"&MAX(IFERROR(AGGREGATE(IF(AGGREGATE(14,6,SUBSTITUTE($D$4:$D$11,"MS","")/($C$4:$C$11=$G4),1)=9,15,14),6,SUBSTITUTE($D$4:$D$11,"MS","")/($C$4:$C$11=$G4),{1,2}),1/10^10)))

  14. #14
    Registered User
    Join Date
    06-30-2021
    Location
    Germany
    MS-Off Ver
    Office 365
    Posts
    27

    Re: Returning highest milestone for ID with INDEX?

    Hi Glenn,

    amazing, this totally works. What do I have to do, if I want do add MS5 and MS6 to the List?

    THANK YOU SO MUCH! Can I invite you to a beer afterwards somehow? Lol.

    Best regards
    Felix

  15. #15
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,129

    Re: Returning highest milestone for ID with INDEX?

    Providing the "rules" do not change and that 9 is the only "problematic" MS value... you can add 5 & 6 in without any further changes.

    I make my own beer (to Rheinheitsgebot standards... of course), so there's never a shortage here...

    You're welcome.



    It would be very nice if you were to just click the Add Reputation button at the foot of any of the posts of members who helped you reach a solution.

    Finally, if that takes care of your original question, please select "Thread Tools" from the menu link above and mark this thread as SOLVED.

  16. #16
    Registered User
    Join Date
    06-30-2021
    Location
    Germany
    MS-Off Ver
    Office 365
    Posts
    27

    Re: Returning highest milestone for ID with INDEX?

    Awesome, are you selling your own beer as well?

    What if I would like to add a Milestone that is called "No Onboarding" (Text Only), which shall be treated silimar to how we treat MS9.

    Is there a way to include it?

    And for some reason, when I transfer the Formula into my List, I get the value "MS0,0000000001" --> EDIT: this should usually only happen, if there are values for an ID, that do not contain "MS", right?
    Last edited by codingflix; 07-02-2021 at 07:16 AM.

  17. #17
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,129

    Re: Returning highest milestone for ID with INDEX?

    It seems that there is a bit of "mission creep" going on now. Please upload a FULLY representative sample along with expected results.

  18. #18
    Registered User
    Join Date
    06-30-2021
    Location
    Germany
    MS-Off Ver
    Office 365
    Posts
    27

    Re: Returning highest milestone for ID with INDEX?

    You are totally right, attached you find a sample.

    I would like to add the Milestone "No Onboarding". This however should only be shown, if there is no Milestone from MS1-MS4 for a Solution.

  19. #19
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,129

    Re: Returning highest milestone for ID with INDEX?

    I'm starting to lose myself here... so this really needs to be 100%!!


    =IF(G4="","","MS"&MAX(IFERROR(AGGREGATE(IF(AGGREGATE(14,6,SUBSTITUTE(SUBSTITUTE($D$4:$D$11,"MS",""),"No Onboarding",1/10^10)/($C$4:$C$11=$G4),1)=9,15,14),6,SUBSTITUTE(SUBSTITUTE($D$4:$D$11,"MS",""),"No Onboarding",1/10^10)/($C$4:$C$11=$G4),{1,2}),1/10^10)))

  20. #20
    Registered User
    Join Date
    06-30-2021
    Location
    Germany
    MS-Off Ver
    Office 365
    Posts
    27

    Re: Returning highest milestone for ID with INDEX?

    That is it! I believe that are all cases included. When I transfer your formula to my table however, the value "MS0,0000000001" still exists if there is a solution that is in milestone "MS9", "No Onbaroding", and "MS1-4". In your solution this isn't a problem however, then I must have made something wrong when copying.

    Absolutely genius what you have done there... Sorry for interative process of getting to the final solution!

  21. #21
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,129

    Re: Returning highest milestone for ID with INDEX?

    Not sure what you mean... but make sure this is included:

    =IF(G4="","", at the start.

    You're welcome.



    It would be very nice if you were to just click the Add Reputation button at the foot of any of the posts of members who helped you reach a solution.

    Finally, if that takes care of your original question, please select "Thread Tools" from the menu link above and mark this thread as SOLVED.

  22. #22
    Registered User
    Join Date
    06-30-2021
    Location
    Germany
    MS-Off Ver
    Office 365
    Posts
    27

    Re: Returning highest milestone for ID with INDEX?

    So I figured to recreate the error.

    Could you have a final look?
    Attached Files Attached Files

  23. #23
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,129

    Re: Returning highest milestone for ID with INDEX?

    Can you check if the following functions are available on your version of Office 365:

    TEXTJOIN
    SORT
    FILTERXML

    If you're using a Mac... forget it, just tell me you're a Mac user.

  24. #24
    Registered User
    Join Date
    06-30-2021
    Location
    Germany
    MS-Off Ver
    Office 365
    Posts
    27

    Re: Returning highest milestone for ID with INDEX?

    Hey Glenn,

    all three are available and no, i dont have a mac =D

  25. #25
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,129

    Re: Returning highest milestone for ID with INDEX?

    One more query... Please DOUBLE check that if you have LET in your Excel version

  26. #26
    Registered User
    Join Date
    06-30-2021
    Location
    Germany
    MS-Off Ver
    Office 365
    Posts
    27

    Re: Returning highest milestone for ID with INDEX?

    LET is not part of the arsenal

  27. #27
    Registered User
    Join Date
    06-30-2021
    Location
    Germany
    MS-Off Ver
    Office 365
    Posts
    27

    Re: Returning highest milestone for ID with INDEX?

    The sam error seems to appear, when I have two milestones for a Solution-ID and the fist one is set to MS9

  28. #28
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,129

    Re: Returning highest milestone for ID with INDEX?

    Bummer. This is a nightmare formula, but it seems to do what's needed.

  29. #29
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,129

    Re: Returning highest milestone for ID with INDEX?

    Scrap that. This looks much better...


    =IFERROR("MS"&SUBSTITUTE(LARGE(IFERROR(LARGE(FILTERXML("<A><B>"&TEXTJOIN("</B><B>",TRUE,FILTER(SUBSTITUTE(SUBSTITUTE(SUBSTITUTE($D$4:$D$14,"MS9","MS0.1"),"MS",""),"No Onboarding",""),$C$4:$C$14=G4))&"</B></A>","//B[.*0=0]"),{1,2}),""),1),0.1,9),"")

  30. #30
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,129

    Re: Returning highest milestone for ID with INDEX?

    or (slightly shorter):

    =IFERROR("MS"&SUBSTITUTE(LARGE(IFERROR(LARGE(FILTERXML("<A><B>"&TEXTJOIN("</B><B>",TRUE,FILTER(SUBSTITUTE(SUBSTITUTE($D$4:$D$14,"MS9","MS0.1"),"MS",""),$C$4:$C$14=G4))&"</B></A>","//B[.*0=0]"),{1,2}),""),1),0.1,9),"")

  31. #31
    Registered User
    Join Date
    06-30-2021
    Location
    Germany
    MS-Off Ver
    Office 365
    Posts
    27

    Re: Returning highest milestone for ID with INDEX?

    Hey Glenn,

    after two hours of trying to figure out your formulas I successfully have managed to incorporate your original formula into my file. All cases are now fully covered!! Amazing work, thank you so much for your help. The shorter version I will try to insert in the upcoming week, when there is again time to use some of your tricks. For now I can create the dashboard that was necessary, BIG HELP!

    Best regards
    Felix

  32. #32
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,129

    Re: Returning highest milestone for ID with INDEX?

    If the one at Post 30 is OK... use it. It'll be much gentler on your PC. If you have any issues, shout. However, for now...

    You're welcome.



    It would be very nice if you were to just click the Add Reputation button at the foot of any of the posts of members who helped you reach a solution.

    Finally, if that takes care of your original question, please select "Thread Tools" from the menu link above and mark this thread as SOLVED.

  33. #33
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,129

    Re: Returning highest milestone for ID with INDEX?

    I woke at 04:00 today and started to think about this one... again. Unusually, I remembered what I was thinking when I woke again a few minutes ago!!

    FINAL iteration:

    =SUBSTITUTE(IFERROR("MS"&MAX(FILTERXML("<A><B>"&TEXTJOIN("</B><B>",TRUE,FILTER(SUBSTITUTE(SUBSTITUTE($D$4:$D$14,"MS9","MS0.1"),"MS",""),$C$4:$C$14=G4))&"</B></A>","//B[.*0=0]")),""),0.1,9)

  34. #34
    Registered User
    Join Date
    06-30-2021
    Location
    Germany
    MS-Off Ver
    Office 365
    Posts
    27

    Re: Returning highest milestone for ID with INDEX?

    I have just tried to incorporate the last two solutions into my sheet. Long story short - I did not succeed. SOmething really strange is happening, when I am trying to alter the values for the Milestones in your table. The results suddenly disappear in the dashboard, and only a restart can bring them back. They look much slicker than the original solution, but there is no way for me to test them.

  35. #35
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,129

    Re: Returning highest milestone for ID with INDEX?

    Away from PC. This is a bit of a nightmare!! One quick check... are calculation options set to manual? Did it work OK on MY sheet when you changed things?

  36. #36
    Registered User
    Join Date
    06-30-2021
    Location
    Germany
    MS-Off Ver
    Office 365
    Posts
    27

    Re: Returning highest milestone for ID with INDEX?

    Calculations are set to Automatic. What does it help to set them to manual?

    No, especially in your spreadsheet I got this weird behavior.

  37. #37
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,129

    Re: Returning highest milestone for ID with INDEX?

    It doesn't help... but might have explained... Back at PC soon.

  38. #38
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,129

    Re: Returning highest milestone for ID with INDEX?

    OK. So, it works PERFECTLY for me. When you open MY file... do you see everything in GERMAN or in ENGLISH?

    Copy/paste the formula that YOU see in H4 of MY file at Post 33. I am wondering if you need a little language-related tweak in the XPath bit of the formula, namely: "//B[.*0=0]"

    Then do the same for the same cell in H4 of THIS file. The only difference is that I used a slightly different construction for the Xpath.

    Also... use formulas/evaluate formula and tell me at what stage it breaks down. EXACYLY what does it say on the click BEFORE an error message is shown.
    Attached Files Attached Files

  39. #39
    Registered User
    Join Date
    06-30-2021
    Location
    Germany
    MS-Off Ver
    Office 365
    Posts
    27

    Re: Returning highest milestone for ID with INDEX?

    I just tried to alter the sample data in your latest file. This one seems to work perfectly fine. Everything is being translated to german automatically, not further tweaking of the language needed =). Ill inset this one tomorrow into my official file.

    I realized one remaining case, that is not fully covered. I created a workaround in my sheet, but is there maybe even a way to fit it into the formula? I have marked the remaining case in the file.
    Attached Files Attached Files

  40. #40
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,129

    Re: Returning highest milestone for ID with INDEX?

    Please double-check your file. Are you sure you have described it correctly (wrong row???)

  41. #41
    Registered User
    Join Date
    06-30-2021
    Location
    Germany
    MS-Off Ver
    Office 365
    Posts
    27

    Re: Returning highest milestone for ID with INDEX?

    Sorry, I made a mistake pointing out the error. My bad.

    Here it is revised.
    Attached Files Attached Files

  42. #42
    Forum Moderator
    Join Date
    01-21-2014
    Location
    St. Joseph, Illinois U.S.A.
    MS-Off Ver
    Office 365 v 2404
    Posts
    13,406

    Re: Returning highest milestone for ID with INDEX?

    Late to the party again.

    This in J4 (of attached) and filled down.
    Formula: copy to clipboard
    Please Login or Register  to view this content.
    Dave

  43. #43
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,129

    Re: Returning highest milestone for ID with INDEX?

    Most strange behaviour!!

    =IFERROR("MS"&SUBSTITUTE(MAX(FILTERXML("<A><B>"&TEXTJOIN("</B><B>",TRUE,FILTER(SUBSTITUTE(SUBSTITUTE($D$4:$D$14,"MS9","MS0.1"),"MS",""),$C$4:$C$14=G4))&"</B></A>","//B[number()=.]")),0.1,9),"")
    Attached Files Attached Files

  44. #44
    Registered User
    Join Date
    06-30-2021
    Location
    Germany
    MS-Off Ver
    Office 365
    Posts
    27

    Re: Returning highest milestone for ID with INDEX?

    Still having the problem of results vanishing.

    I believe the solution of flameretired is working as well, even though I again cannot make sense of your formula. I'll see if I can fit it into my table.

  45. #45
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,129

    Re: Returning highest milestone for ID with INDEX?

    Go with FR's. I can't understand what's happening!!

  46. #46
    Registered User
    Join Date
    06-30-2021
    Location
    Germany
    MS-Off Ver
    Office 365
    Posts
    27

    Re: Returning highest milestone for ID with INDEX?

    @FlameRetired, there is still one anomaly remaining in your formula. When two Milestones are stated for a given Solution ID, and the second of the two milestones (lower in the table) is on MS9, no matter what the first (higher in the table) Milestone states, the result is still MS9.

    Could you have a final look? Problem is demonstrated in the attached file.

    Thanks

  47. #47
    Registered User
    Join Date
    06-30-2021
    Location
    Germany
    MS-Off Ver
    Office 365
    Posts
    27

    Re: Returning highest milestone for ID with INDEX?

    Actually the wrong Milestone always appears if MS9 is the milestone for the lowest row for a solution-ID.

  48. #48
    Forum Moderator
    Join Date
    01-21-2014
    Location
    St. Joseph, Illinois U.S.A.
    MS-Off Ver
    Office 365 v 2404
    Posts
    13,406

    Re: Returning highest milestone for ID with INDEX?

    OK

    I think I got it right this time.

    Try this one. As long as the Milestone figures are always prefixed "MS" this will work.
    Formula: copy to clipboard
    Please Login or Register  to view this content.
    Last edited by FlameRetired; 07-06-2021 at 11:36 PM.

  49. #49
    Registered User
    Join Date
    06-30-2021
    Location
    Germany
    MS-Off Ver
    Office 365
    Posts
    27

    Re: Returning highest milestone for ID with INDEX?

    The error sadly still exists. Can be recreated always when MS9 is in the lowest row for a given Solution-ID.

    Have a look.

  50. #50
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,129

    Re: Returning highest milestone for ID with INDEX?

    I still see the correct answer in the purple cells in your sheet. Incidentally, you ignored my Qs back ay Post 38...

  51. #51
    Registered User
    Join Date
    06-30-2021
    Location
    Germany
    MS-Off Ver
    Office 365
    Posts
    27

    Re: Returning highest milestone for ID with INDEX?

    I checked the sample, the one you are describing does not seem to have the error.

    However if I only have MS9, or MS9 and "No Onbording", the result is always MS0 instead of MS9.
    Attached Files Attached Files

  52. #52
    Forum Moderator
    Join Date
    01-21-2014
    Location
    St. Joseph, Illinois U.S.A.
    MS-Off Ver
    Office 365 v 2404
    Posts
    13,406

    Re: Returning highest milestone for ID with INDEX?

    OK I think I understand.

    Formula: copy to clipboard
    Please Login or Register  to view this content.



    C
    D
    E
    F
    G
    H
    I
    1
    General Table
    Dashboard
    2
    3
    Solution-ID
    Milestone
    Solution-ID
    4
    1
    MS4
    1
    MS4
    5
    2
    MS2
    2
    MS2
    6
    2
    MS9
    3
    MS9
    <- should be MS9
    7
    3
    MS9
    4
    MS4
    8
    3
    MS9
    5
    9
    3
    No Onboarding
    6
    MS9
    <- should be MS9
    10
    3
    No Onboarding
    7
    11
    4
    MS4
    12
    5
    No Onboarding
    13
    6
    MS9
    14
    6
    MS9

  53. #53
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,129

    Re: Returning highest milestone for ID with INDEX?

    I think I may have fixed it!! However, I do not have the first idea why it made a difference!!!

    =SUBSTITUTE(IFERROR("MS"&MAX(FILTERXML("<A><B>"&TEXTJOIN("</B><B>",TRUE,FILTER(SUBSTITUTE(SUBSTITUTE($D$4:$D$14,"MS9","MS0.1"),"MS",""),$C$4:$C$14=G4))&"</B></A>","//B[number()=.]")),"")&"",0.1,9)
    Attached Files Attached Files

  54. #54
    Registered User
    Join Date
    06-30-2021
    Location
    Germany
    MS-Off Ver
    Office 365
    Posts
    27

    Re: Returning highest milestone for ID with INDEX?

    sorry for the late reply. Got knocked out with fever due to second covid vaccination...

    regarding your Solution FM:
    I'm not sure about your updated solution (V5). Now most of the times the results are wrong, your initial solution was much closer to where I have to be. In your recent solution the results are shown correct, but when changing the milestones in the file, the results do not comply with the necessary rules.

    Here all the rules, that have to apply:

    The Dashboard has to show the highest milestone for a given Solution-ID. A solution ID can have multiple milestones:
    - if for a given solution-ID there is MS9 and no other milestone, then MS9
    - if for a given solution-ID there is MS9 and MS0-MS6, then MS0-MS6
    - if for a given solution-ID there is MS9, "No Onboarding", and MS0-MS6, then MS0-MS6
    - if for a given solution-ID there is MS9 and "No Onboarding", then MS9
    - if for a given solution-ID there is MS0-MS6 and "No Onboarding", then MS0-MS6
    - if for a given solution-ID there is only "No Onboarding", then ""

  55. #55
    Registered User
    Join Date
    06-30-2021
    Location
    Germany
    MS-Off Ver
    Office 365
    Posts
    27

    Re: Returning highest milestone for ID with INDEX?

    @Glenn:

    I dont know whats happening anymore. I have attached a screenshot of what happens, when I change a single Milestone in the list. The results for Solution-ID 1, 3 and 6 change, despite them originally being correct.

    What is going on here...Attachment 739638

  56. #56
    Forum Guru
    Join Date
    08-28-2014
    Location
    USA
    MS-Off Ver
    Excel 2019
    Posts
    17,606

    Re: Returning highest milestone for ID with INDEX?

    Selecting Attachment 739638 results in the following message: "Invalid Attachment specified. If you followed a valid link, please notify the administrator".
    Consider taking the time to add to the reputation of everybody that has taken the time to respond to your query.

  57. #57
    Registered User
    Join Date
    06-30-2021
    Location
    Germany
    MS-Off Ver
    Office 365
    Posts
    27

    Re: Returning highest milestone for ID with INDEX?

    Weird. Reupload.Weird error.PNG

  58. #58
    Forum Guru
    Join Date
    08-28-2014
    Location
    USA
    MS-Off Ver
    Excel 2019
    Posts
    17,606

    Re: Returning highest milestone for ID with INDEX?

    This proposal employs a helper column (E) which may be moved and/or hidden for aesthetic purposes.
    The helper column is populated using: =IFERROR(AGGREGATE(14,6,(RIGHT(D$4:D$15)+0)/((RIGHT(D$4:D$15)+0)<=6)/(C$4:C$15=C4),1),AGGREGATE(15,6,RIGHT(D$4:D7)+0/(C$4:C$15=C4),1))
    The output is produced using: =IFERROR("MS"&INDEX(E$4:E$15,MATCH(G4,C$4:C$15,0)),"")
    Let us know if you have any questions.

  59. #59
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,129

    Re: Returning highest milestone for ID with INDEX?

    JeteMc... can I ask you t look at the file at Post 53. Does it work OK for you?? It's fine here, but seems to fall over on the OP's system.

  60. #60
    Forum Guru
    Join Date
    08-28-2014
    Location
    USA
    MS-Off Ver
    Excel 2019
    Posts
    17,606

    Re: Returning highest milestone for ID with INDEX?

    Glen, I can see the outputs of the formulas, which are correct, when I open the file and even when I select "Enable Editing". However, when I make any change, such as changing D4 from MS4 to MS3 all of the outputs disappear. I am using the 2019 version which does not support FILTERXML nor FILTER. As codingflix is using the 365 version, my issue may not be codingflix's.

  61. #61
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,129

    Re: Returning highest milestone for ID with INDEX?

    OK. Thanks. I'll pester someone else with 365...

  62. #62
    Forum Guru
    Join Date
    08-28-2014
    Location
    USA
    MS-Off Ver
    Excel 2019
    Posts
    17,606

    Re: Returning highest milestone for ID with INDEX?

    You're Welcome. I was glad to take a look and hope that the issue can be sorted. I hope that you have a blessed day.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Replies: 4
    Last Post: 04-25-2021, 05:27 AM
  2. Returning The 5 Name of the highest 5 value field
    By Biplab1985 in forum Excel General
    Replies: 3
    Last Post: 10-25-2016, 02:25 PM
  3. Returning Highest Value in Countif
    By riff100 in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 05-20-2015, 05:48 PM
  4. Returning next highest value from =small(if.....)
    By MARKSTRO in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 11-02-2012, 05:12 PM
  5. [SOLVED] Returning the 5 highest values in a row.
    By LucG in forum Excel Formulas & Functions
    Replies: 10
    Last Post: 07-24-2012, 02:36 PM
  6. Excel 2007 : Returning the highest value in a range
    By JohnJC in forum Excel General
    Replies: 3
    Last Post: 10-01-2010, 08:45 AM
  7. Returning highest value
    By Fishbone in forum Excel General
    Replies: 7
    Last Post: 08-12-2005, 10:05 AM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1