show comparison in another columns

show comparison in another columns

wintermelon_loverwintermelon_lover Posts: 6Questions: 5Answers: 0
edited July 20 in Free community support

Link to test case:
Description of problem: I currently have two tables and each table was like:


Can I merge them to a table like:

by grouping them with index and compute weight loss with Datatables?

This question has an accepted answers - jump to answer


  • kthorngrenkthorngren Posts: 13,851Questions: 25Answers: 3,262
    Answer ✓

    The diff column would require rowspan to be used which isn't supported, by Datatables, in the tbody. One option might be to use the RowGroup extension. You can group by the index column then output the difference in the row added by RowGroup. For example:

    There are some comments in the example. See this example for rowGroup.endRender for more details.


Sign In or Register to comment.