Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Hi!
So I'm currently working on some powerBI stuff, and I have a database table which is hierarchic, meaning I have something like this:
__id___Place______id_parent
Equivalent to something like that:
I've found out I can use PATH() that gives me a list of id's from parent to my selected node, but how to go from (7, 5, 4, 1) to "Floor1 => Building1 => MyInc => London" string?
Thanks by advance for your support
Hi @Anonymous ,
Do you want to achieve a string-like purpose through the path() function? For example, the following test I did. If you misunderstand what you mean, can you further clarify your needs, provide accurate test data and expected results, I will answer you as soon as possible.
Column = PATH('Table'[Employee],'Table'[ReportingTo])
You can also refer to related blogs:
How to Retrieve Data Recursively with Power BI
Recursive Functions in Power BI / Power Query — Powered Solutions
Looking forward to your reply.
Best Regards,
Henry
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi!
In my first atempt I was using the ids of the lines and was getting "1|2|6" and was trying to figure out how to make it look like what you've shown... but I can just make a new column with name depending on id, and then use it as recursive PATH!
Thanks a lot!
now is there a way to take that CEO|VP|AVP and make it look like "CEO -> VP -> AVP" ? it would be perfect!
that would totally fit my need!
Thanks again for your help
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
98 | |
97 | |
81 | |
77 | |
66 |
User | Count |
---|---|
126 | |
105 | |
103 | |
81 | |
72 |