You’re absolutely right that it comes down to the specifics of the question(s) being asked in determining the right approach here. In this case, I interpreted the language of the initial brief (" The ability to see status changes and when they happened) as pertaining to changes in the Complaint Status ID. WIth this interpretation, intra-complaint information that doesn’t result in a change in status is extraneous.
However, in your case the problem is specifically defined such that those repeating status entries are relevant. To make the previous value pattern work, you must have a column that is continually increasing within the scope of the calculation (in this case, has to be increasing within a given complaint, since we don’t care in this calculation at least, about status changes across complaints). The increase doesn’t have to be uniform, but it does have to be continuous( e.g., 1, 14, 67, 195 works just as well as 1, 2, 3, 4).
In your case above, a Power Query transformation of the timestamp, removing “Timestamp”, the hyphen, and converting the remaining digits from text to whole number looks like it will work perfectly, since it will serve as an increasing identifier within the right scope that will make the “repeating” entries now unique.
I hope this is helpful. It is interesting to see how frequently the challenges mirror real life. WIth every challenge that goes by, I find that I am incorporating more and more of what I learn (and steal from others… ) in my work reports, despite the fact that none of them are substantively similar to the work I do, which is a real credit to @haroonali1000 and how broadly relevant he has constructed these scenarios to be.
- Brian