Forum Discussion
Find like
- 4 years ago
Hi slyfox ,
1. In your data, if the values of the [User Name] column with similar user name are empty, then you can just delete the rows with empty values of column [User Name].
2. Or you can add a custom column and remove the rows that satisfy the condition: [User Name.1] = [Standard Name].
= Text.Select([User Name.1], {"a".."z","A".."Z"})And the complete code is as follows:
let Source = Table.FromRows(Json.Document(Binary.Decompress(Binary.FromText("i45WsjA2tzRS0lEKTsxNzCtJVAjOzSzJUAAJ+AIZSrE60UqWRhZmxkARmGC8IVgYKGpiiCxsBBY2BBuWpxCVkZiXDmFDlEOVJuaB9McCAA==", BinaryEncoding.Base64), Compression.Deflate)), let _t = ((type nullable text) meta [Serialized.Text = true]) in type table [Id = _t, #"User Name" = _t, #"User Name.1" = _t]), #"Changed Type" = Table.TransformColumnTypes(Source,{{"Id", Int64.Type}, {"User Name", type text}, {"User Name.1", type text}}), #"Added Custom" = Table.AddColumn(#"Changed Type", "Standard Name", each Text.Select([User Name.1], {"a".."z","A".."Z"})), #"Filtered Rows" = Table.SelectRows(#"Added Custom", each ([User Name.1] = [Standard Name])) in #"Filtered Rows"If the problem is still not resolved, please provide detailed error information or the expected result you expect. Let me know immediately, looking forward to your reply.
Best Regards,
WinnizIf this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi slyfox ,
1. In your data, if the values of the [User Name] column with similar user name are empty, then you can just delete the rows with empty values of column [User Name].
2. Or you can add a custom column and remove the rows that satisfy the condition: [User Name.1] = [Standard Name].
= Text.Select([User Name.1], {"a".."z","A".."Z"})
And the complete code is as follows:
let
Source = Table.FromRows(Json.Document(Binary.Decompress(Binary.FromText("i45WsjA2tzRS0lEKTsxNzCtJVAjOzSzJUAAJ+AIZSrE60UqWRhZmxkARmGC8IVgYKGpiiCxsBBY2BBuWpxCVkZiXDmFDlEOVJuaB9McCAA==", BinaryEncoding.Base64), Compression.Deflate)), let _t = ((type nullable text) meta [Serialized.Text = true]) in type table [Id = _t, #"User Name" = _t, #"User Name.1" = _t]),
#"Changed Type" = Table.TransformColumnTypes(Source,{{"Id", Int64.Type}, {"User Name", type text}, {"User Name.1", type text}}),
#"Added Custom" = Table.AddColumn(#"Changed Type", "Standard Name", each Text.Select([User Name.1], {"a".."z","A".."Z"})),
#"Filtered Rows" = Table.SelectRows(#"Added Custom", each ([User Name.1] = [Standard Name]))
in
#"Filtered Rows"
If the problem is still not resolved, please provide detailed error information or the expected result you expect. Let me know immediately, looking forward to your reply.
Best Regards,
Winniz
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.