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 am quite new to Power BI.
I have a table (direct query) with 3 columns
Date - Male_KPI - Female_KPI
23/5/2019 - 8000 - 7000
22/5/2019 - 7000 - 8000
I need a new table with this structure
Date - Gender(M/F) - KPI
23/5/2019 - M- 8000
23/5/2019 - F - 7000
22/5/2019 - M- 7000
22/5/2019 - F - 8000
where the gender is M or F.
How to do that?
Roberto
if it wasn't Direct Query my guess would be to use unpivot in the Query Editor - but I guess it switches the table to Import mode, correct?
Otherwise I guess you can do it in DAX using UNION and SELECTCOLUMNS
https://dax.guide/union/
https://dax.guide/selectcolumns/
But I guess the most efficent performance wise would be creating the view in your database
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 |
---|---|
99 | |
50 | |
19 | |
12 | |
11 |