Problem: I run a script to load data from a database. I delete all formulas from the data table. I copy the table script using the red triangle menu. I paste the table script into a script window. I run the script. The table resulting from the table script has different column grouping and throws some of the columns around (see screenshot).

I suspect that this is due to the table script not preserving leading whitespace in column names. Most of the columns in column groups "Result" and "Units of measurement" have identical names, but are different in that one of the groups has leading whitespace as part of the column name (which I thought was super smart, because I could then keep the columns separated for some operations...).
Any quick fixes to resolve this are highly welcome.