Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more
I want to use the Table header value as the column name in a merge query I have (from a previous question)
#"Merged Columns" = Table.CombineColumns(#"Trimmed Text",mergeHeaders[headers],Combiner.CombineTextByDelimiter("|", QuoteStyle.None),"Merged")
I have tried replacing Merged with mergeHeaders[headers] but get the error
Expression.Error: We cannot convert a value of type List to type Text.
Details:
Value=[List]
Type=[Type]
I have also tried mergeHeaders[headers]{0} I get no error but the merge no longed outputs data
Thank you
Solved! Go to Solution.
Use this in place of mergeHeaders[headers]
Text.BetweenDelimiters("mergeHeaders[headers]","[","]")
Note - For this merge to work, you require at least 2 column names which exist in #"Trimmed Text". This result should appear in the place where you would place this. Refer the doc here - https://docs.microsoft.com/en-us/powerquery-m/table-combinecolumns
Use this in place of mergeHeaders[headers]
Text.BetweenDelimiters("mergeHeaders[headers]","[","]")
Note - For this merge to work, you require at least 2 column names which exist in #"Trimmed Text". This result should appear in the place where you would place this. Refer the doc here - https://docs.microsoft.com/en-us/powerquery-m/table-combinecolumns
Yes, that's great! Thank you again
The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!