Hi
I have attached a picture that shows a table with dummy values.
My requirement is to group values in the table similar to that specified in the picture.
As per the example shown in the picture, the table is grouped by the first column. So the two groups are 'AAAA' and 'BBBB'. 'AAAA' has three elements under it (XXXX, YYYY, ZZZZ) - odd number of elements and 'BBBB' has six elements under it (PPPP, QQQQ, RRRR, SSSS, TTTT, UUUU) - even number of elements.
If the number of elements in a group are odd, then the group name, here, AAAA, should be displayed in the [(n/2) + 0.5]th row in its cell. For the example, number of elements = 3. [(3/2) + 0.5] = 2, so the value - 'AAAA' should be displayed in the second row inside the cell.
If the number of elements is even, then the group name, here, 'BBBB', should be displayed between the [n/2]nd row and [(n/2)+1]th row. For the example, number of elements = 6. [6/2] = 3 and [(6/2)+1] = 4. So the group name should be displayed between the 3 rd and 4th row in the cell.
In the figure attached for understanding, the grey lines shown in the first column are only for understanding and shouldnot be displayed in the report.
Can someone help me with this.
Thanks in advance