Pivot Table Manipulation

Hi there,

I need to display the group and the pivot in the same column with order and the manuel agregation in two other culumn… I hope you understand my problem …!!

The simplest you can do, unpivot the table, save it as Excel and use standard Excel pivot.

1 Like


you can sum all those columns with the Column Aggregator node.
Alternatively, you can also use the second output of the pivoting node. There you always have the group aggregation calculated.

Was this what you are looking for?
Cheers, Iris

1 Like

Hi there
maybe you need to use the joiner node to put all together…

1 Like

@TIZIZ Unpivot the data so that you have a normalised DEX and then the columns for each column following it, then group the data by DEX and sum the values. Can you upload the spreadsheet so I can have an attempt??

Apologies for my lack of French @TIZIZ

I think I understand what your requirement was.This is what I have done -

  • Instead of using the Pivot node, I used two GroupBy nodes, one for DEX and one for DSSC, to sum the traffic values
  • then used the Unpivoting node to get the same column names,
  • and then Concatenate node to merge them together, like a UNION command in SQL.
  • finally cleaned up the column names.
  • outputs the results to an Excel file in the Knime workflow but you can change this to whatever you require

Is that what you wanted? You can do the same thing with the Pivot node, but it requires more work. I will do this tonight so I can show you how it works.

The workflow is attached here -

DEX_DSSC_example.knar (71.5 KB)

1 Like

Here is the version using the Pivot node. It is not as elegant!

Note that the Pivot node has three output ports, and you can use them to get the totals for the columns or rows in the pivot table.

DEX_DSSC Pivot Table.knwf (18.3 KB)

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.