Forum Discussion
labuser1235
6 years agoHelper IV
Pivot creates duplicate values
Hi All, I am trying to create a pivot for different types in a column. However, it creates multiple TIDs based because of the pivot. I am aware that I can use fill up or fill down so that I ...
- Anonymous6 years ago
Hi labuser1235 ,
Remove the FID column and pivot Fname column with Fdata as value column should work.
Best Regards,
Jay
Community Support Team _ Jay Wang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
nandukrishnavs
6 years agoCommunity Champion
Try this PQ
let
Source = Table.FromRows(Json.Document(Binary.Decompress(Binary.FromText("bdI7DsMgEEXRrSBqR4JhwGnz20E6y2X6tNl9TOyR3mNSWLJ1QL4aWJaoWuIU8/Y8P+/X6dI/UlwnEzG5dqkgxeTWl6Goyb0vQ6kmj+2lHf9pzRcgDQlI1BAAhgTcMzTslEVdhCBxhCL9idiBIwru4YhjEq1mF5GRKCIA8FkI7uGIM9IwiflHs7jjCAA8h1SBOIKIIxKIuxHrFw==", BinaryEncoding.Base64), Compression.Deflate)), let _t = ((type nullable text) meta [Serialized.Text = true]) in type table [TID = _t, FID = _t, Fname = _t, Fdata = _t]),
#"Removed Columns" = Table.RemoveColumns(Source,{"FID"}),
#"Pivoted Column" = Table.Pivot(#"Removed Columns", List.Distinct(#"Removed Columns"[Fname]), "Fname", "Fdata")
in
#"Pivoted Column"
Did I answer your question? Mark my post as a solution!
Appreciate with a kudos 🙂