I wish this help you Looks like a perfectly standard grouping problem. Therefore considerably easier in XSLT 2.0. Use xsl:for-each-group in XSLT 2.0; use Muenchian grouping if you're stuck with XSLT 1.0. Read up on grouping techniques and come back here if you are still stuck.
XSLT to transform to HTML and format the HTML based on data in XML
By : Koto
Date : March 29 2020, 07:55 AM
like below fixes the issue Below is a solution that applies up to 20 different colors - applying one particular color for each row with a specific testid. Note that it is not important how many distinct testid's occur. Also note that color coding says nothing about the testid itself - but that's exactly the way you wanted it :-).
it helps some times I know that's easy, but I tried and XSLT is really non-understandable for me... That is why I would like to have an example over my code so I could examine it on real-case example and probably understand it. , Here is a stylesheet that does the transform: