Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.
Sign up nowGet Fabric certified for FREE! Don't miss your chance! Learn more
Hello guys,
I have a table that looks like this:
| Department | Mar '23 Spend | Apr '23 Spend | May '23 Spend |
| Retail | 23.00 | 11.33 | 30.92 |
| Businesses | 0.70 | 1.56 | 2.33 |
| Private | 1.33 | 5.00 | 0.88 |
How can I replace each of the value in the column that has numerical value to the multiple of 1000 in power query.
The result should look like this:
| Department | Mar '23 Spend | Apr '23 Spend | May '23 Spend |
| Retail | 23000 | 11330 | 30920 |
| Businesses | 700 | 1560 | 2330 |
| Private | 1330 | 5000 | 880 |
Thank you in advance
Solved! Go to Solution.
Hello! This will do it.
et
Source = Table.FromRows(Json.Document(Binary.Decompress(Binary.FromText("i45WCkotSczMUdJRMjLWMzAA0oaGesbGQNrYQM/SSClWJ1rJqbQ4My+1uDi1GChsoGcOVqVnagbSBFILUhNQlFmWWJIKlgFrN4WYZqBnYaEUGwsA", BinaryEncoding.Base64), Compression.Deflate)), let _t = ((type nullable text) meta [Serialized.Text = true]) in type table [Department = _t, #"Mar '23 Spend" = _t, #"Apr '23 Spend" = _t, #"May '23 Spend" = _t]),
#"Changed Type" = Table.TransformColumnTypes(Source,{{"Department", type text}, {"Mar '23 Spend", type number}, {"Apr '23 Spend", type number}, {"May '23 Spend", type number}}),
Custom2 = Table.ReplaceValue(#"Changed Type",each 1000,"",(x,y,z)=>x*y,{"Mar '23 Spend","Apr '23 Spend","May '23 Spend"})
in
Custom2
Hello! This will do it.
et
Source = Table.FromRows(Json.Document(Binary.Decompress(Binary.FromText("i45WCkotSczMUdJRMjLWMzAA0oaGesbGQNrYQM/SSClWJ1rJqbQ4My+1uDi1GChsoGcOVqVnagbSBFILUhNQlFmWWJIKlgFrN4WYZqBnYaEUGwsA", BinaryEncoding.Base64), Compression.Deflate)), let _t = ((type nullable text) meta [Serialized.Text = true]) in type table [Department = _t, #"Mar '23 Spend" = _t, #"Apr '23 Spend" = _t, #"May '23 Spend" = _t]),
#"Changed Type" = Table.TransformColumnTypes(Source,{{"Department", type text}, {"Mar '23 Spend", type number}, {"Apr '23 Spend", type number}, {"May '23 Spend", type number}}),
Custom2 = Table.ReplaceValue(#"Changed Type",each 1000,"",(x,y,z)=>x*y,{"Mar '23 Spend","Apr '23 Spend","May '23 Spend"})
in
Custom2
Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.
| User | Count |
|---|---|
| 12 | |
| 11 | |
| 11 | |
| 7 | |
| 6 |