Table of contents
TOC
Collapse the table of content
Expand the table of content

Table.FromPartitions

Owen Duncan|Last Updated: 4/19/2018

About

Returns a table that is the result of combining a set of partitioned tables into new columns. The type of the column can optionally be specified, the default is any.

Table.FromPartitions ( partitionColumn as text, partitions as list, optional partitionColumnType as nullable type) as table  

Arguments

ArgumentDescription
partitionColumnThe name of the column where the values from the paritions will added.
partitionsThe list of partitions to combine, specificed in {value, table} pairs.
Optional partitionColumnTypeThe type of the resulting column (default is any).

Example

Table.FromPartitions("Year",  

{{1994, Table.FromPartitions("Month", {  

    {"Jan", Table.FromPartitions("Day", {  

        {1, #table({"Column1"},{{"Column1 Value 1"}})},  

        {2, #table({"Column1"},{{"Column1 Value 2"}})}})},  

        {"Feb", Table.FromPartitions("Day",  

        {{3, #table({"Column1"},{{"Column1 Value 3"}})},  

        {4,  #table({"Column1"},{{"Column1 Value 4"}  

})}})}})}})  

equals  
Column1DayMonthYear
Column1 Value 11Jan1994
Column1 Value 22Jan1994
Column1 Value 33Feb1994
Column1 Value 44Feb1994
© 2018 Microsoft