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 a table like this -
Title | Request Start Date | Request End Date | Targeted Start Date | Targeted End Date | Actual Start Date | Actual End Date |
Item 1 | 7/30/2021 | 9/30/2021 | 7/30/2021 | 9/30/2021 | 5/30/2021 | 7/30/2021 |
Item 2 | 7/30/2021 | 9/30/2021 | 7/30/2021 | 9/30/2021 | 5/30/2021 | 7/30/2021 |
I need to transform it to something like this
Title | Date Category | Start Date | End Date |
Item 1 | Request Date | 7/30/2021 | 9/30/2021 |
Item 1 | Targeted Date | 7/30/2021 | 9/30/2021 |
Item 1 | Actual Date | 5/30/2021 | 7/30/2021 |
Item 2 | Request Date | 7/30/2021 | 9/30/2021 |
Item 2 | Targeted Date | 7/30/2021 | 9/30/2021 |
Item 2 | Actual Date | 5/30/2021 | 7/30/2021 |
I tried unpivoting all the start date columns and the end date columns from the first table but that gives me a cartesian product. IS there a way to do thi
Solved! Go to Solution.
Select the first column. Unpivot the othe columns.
Split the centre column (by space, once as far left as possible)
Select the new column that has 'start date' and 'end date' in it. Pivot this column. Choose Value(the date column) as Values. Choose Don't Aggregate from the advanced.
That should be it.
Perfect. Thank you.
Select the first column. Unpivot the othe columns.
Split the centre column (by space, once as far left as possible)
Select the new column that has 'start date' and 'end date' in it. Pivot this column. Choose Value(the date column) as Values. Choose Don't Aggregate from the advanced.
That should be it.
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 |
---|---|
107 | |
93 | |
77 | |
65 | |
53 |
User | Count |
---|---|
147 | |
106 | |
104 | |
87 | |
61 |