How to manage the table component of a report when column number can change at runtime

Hi folks, I have this controversial question that I can’t solve.
In my project, I show the table with a number of columns that can change during the runtime operation.
The operator has to print this information at runtime and I have made a report showing all the information
using table and graph. What is the smarter way to manage the table in my report to dynamically fit the table as the number of columns in the dataset that I pass to it changes? I don’t think many develop
report is the smartest solution, but I can’t figure out what to do on my report to make it dynamic in this situation!

https://docs.inductiveautomation.com/display/DOC81/Report+-+Simple+Table
maybe idk i’ve not realy done alot with reports yet

This approach is probably the best you can do:

TL/DR:

Reporting tables cannot have variable numbers or columns, nor variable column names. You can fake it to a certain extent by hiding columns and using other variables for the column names in the table header. Consider using a script data source to transform any given dataset to have the needed column names while populating the variables for the column headers from that given dataset. And hiding the unused columns.

Good luck.