Forum Discussion
Performance issue at expanding or combining tablecolumn
- 6 years ago
Hi JVos,
you're right, sorry, my bad :(
Please read my new blog post, it should help with the performance: https://community.powerbi.com/t5/Community-Blog/Transitive-Closure-in-Power-Query/ba-p/782678
Hi Nolock,
Your proposal omits the indirect relations in the final result. Note that the initial code - in the solution you refer to - was:
TableOfDescendents = Table.AddColumn(ChangedType, "TableOfDescendents", each fnTransitiveRelationTable(ChangedType, [From])),
TableOfAllDescentantsTables = Table.Combine({ChangedType, Table.Combine(TableOfDescendents[TableOfDescendents])}),To see what happens step-by-step, I broke the last line into two lines of code:
TableOfDescendents = Table.AddColumn(ChangedType, "TableOfDescendents", each fnTransitiveRelationTable(ChangedType, [ROUTING_ID_From])),
CombinedDescendents = Table.Combine(TableOfDescendents[TableOfDescendents]),
TableOfAllDescentantsTables = Table.Combine({ChangedType, CombinedDescendents}),Now you propose in fact to remove to combine TableOfDescendents[TableOfDescendents], which makes that the indirect relations are not in the end result.
Hi JVos,
you're right, sorry, my bad :(
Please read my new blog post, it should help with the performance: https://community.powerbi.com/t5/Community-Blog/Transitive-Closure-in-Power-Query/ba-p/782678