Forum Discussion
ramankr48
Helper II
1 year agoHow can I split a variable-depth, slash-delimited path_column field into separate col in KQL?
Q : How can I split a variable-depth, slash-delimited path_column field into separate path_lvl_1, path_lvl_2, … columns in Kusto (Fabric) so that Power BI (in DirectQuery mode) can consume a fixed sc...
- 1 year ago
Sure thing - just remove the column defintion fret the pivot function. Then the previous query will be dynamic
ramankr48
Helper II
1 year agoI don't think it will work if no of values gets increased in the values column, will it be feasible or change the schema on the fly
datacoffee
Most Valuable Professional
1 year agoSure thing - just remove the column defintion fret the pivot function. Then the previous query will be dynamic
- ramankr481 year ago
Helper II
T
| extend ColSplit = split(values, "/")
| mv-expand ColIndex = range(0, array_length(ColSplit), 1)
| extend columnName = strcat("col", tostring(ColIndex + 1)), columnValue = ColSplit[ColIndex]
| evaluate pivot(columnName, any(columnValue))
| project-away ColSplit, ColIndex