Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.
For a very simple example, say I have table with rows:
{name = a, M1 = 10, M2 = 20},
{name = a, M1 = 15, M2 = 10},
{name = b, M1 = 15, M2 = 10}
So obviously we can combine this (say with sum) to just give us:
{name = a, M1 = 25, M2 = 30}
{name = b, M1 = 15, M2 = 10}
When I plot this (say clustered column chart), it will have names (a and b) on the axis, and the values of M1/M2 for each index as clustered column bars. For example, name "a" will be on the axis and have two bars for M1 = 25, M2 = 30.
My question is, is it possible to flip this to be M1 on the axis with two bars with a = 25 and b = 15? I can make a complicated function that regoups M1/M2 using power query m, but it is slow and I think there must be a simpler way or that I am not approaching this the correct way. Essentially, I can make the table below and get this to work, but it is not optimal.
{month = M1, a = 25, b = 15}
{month = M2, a = 30, b = 10}
Solved! Go to Solution.
The simple way is to use unpivot columns in Query Editor.
The simple way is to use unpivot columns in Query Editor.
User | Count |
---|---|
103 | |
88 | |
78 | |
71 | |
69 |
User | Count |
---|---|
113 | |
99 | |
97 | |
72 | |
68 |