OpenBI Docs Buy

Table.ToColumns

A table's columns as a list of lists: one list of values per column.

Group: Table. Power Query M has it too: a query that uses it is written as in Power BI.

Syntax

Table.ToColumns(table as table) as list
ParameterTypeDescription
tabletableThe table to take apart.

Returns

list. A list per column, in column order, each with the column's values from top to bottom.

Remarks

  • The column names are not part of it; Table.FromColumns builds a table from such a list again.

Examples

Two columns

Table.ToColumns(#table({"Product", "Price"}, {{"Chair", 50}, {"Desk", 120}}))
{{"Chair", "Desk"}, {50, 120}}

Table.FromColumns, Table.ToRows, Table.Column, Table.ToRecords.

Last updated · OpenBI Studio 0.3.79