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
I have one table DimEmployee with employee data and it contains column named Country . I want to create calculated column to generate unique key for each country. so in below example column like "CountryId". How to do this ?
Solved! Go to Solution.
Yes just use Rank
this will give them a unique id based on alphibetial order of country
Proud to be a Super User!
The easiest way to do this is to just add a manually entered table with ID and Country
you can the join on the country to get the id
if you are wanting to dynamically create an id because you do not know what the country names will be then use a RANKX colunm will give a unique number for each country
Proud to be a Super User!
I want to do it dynamically and I do not have any country table so I want to do this in DimEmployee itself. Is it doable ?
Yes just use Rank
this will give them a unique id based on alphibetial order of country
Proud to be a Super User!
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 |
---|---|
113 | |
99 | |
80 | |
70 | |
60 |
User | Count |
---|---|
149 | |
114 | |
107 | |
89 | |
67 |