|
[广告] Excel易用宝 - 提升Excel的操作效率 · Excel / WPS表格插件 ★ 免费下载 ★ ★ 使用帮助★
- let
- 源2 = Excel.CurrentWorkbook(){[Name = "表1"]}[Content],
- 更改的类型2 = Table.TransformColumnTypes(源2, {{"列1", type date}}),
- lst = List.Accumulate(Table.ToRows(更改的类型2), {}, (x, y) => x & List.Repeat({y{0}}, y{1})),
- 源 = Excel.CurrentWorkbook(){[Name = "表2"]}[Content],
- 自定义1 = List.Combine(Table.ToRows(源)),
- 自定义2 = List.Accumulate(
- 自定义1,
- {{}, lst},
- (x, y) => {x{0} & {List.FirstN(x{1}, y)}, List.RemoveFirstN(x{1}, y)}
- ){0},
- 自定义3 = Table.Combine(
- List.Transform(
- 自定义2,
- each [
- a = Table.FromColumns({_}),
- b = Table.Group(a, "Column1", {"all", each Table.RowCount(_)}),
- c = Table.ToColumns(b),
- d = Record.FromList(c{1}, List.Transform(c{0}, Text.From)),
- e = Table.FromRecords({d})
- ][e]
- )
- )
- in
- 自定义3
复制代码 |
|