Cube.CollapseAndRemoveColumns is a function in the Power Query M language that changes the dimensional granularity of a cube’s filter context by collapsing attributes mapped to specified columns. The function returns a modified cube with the columns removed and the new dimensional granularity.

Compatible with: Power BI Service Power BI Desktop Excel Microsoft 365


   cube as table,
   columnNames as list,
) as table


Changes the dimensional granularity of the filter context for the cube by collapsing the attributes mapped to the specified columns columnNames. The columns are also removed from the tabular view of the cube.

Other functions related to Cube.CollapseAndRemoveColumns are:

BI Gorilla Youtube Channel

Last update: August 17, 2023 | Contribute » | Contributors: Rick de Groot
Microsoft documentation:
© 2023 BI Gorilla. All rights reserved. Content derived from Microsoft documentation is property of Microsoft Corp.