Forum Discussion

Cipriano's avatar
Cipriano
Helper III
2 years ago
Solved

Table scan and joining data in a sigle value

Hello, everyone! To check if it is possible to read a data table to obtain a summary view of the data, I basically need to integrate data using a table scan, joining the values of one of its columns...
  • edhans's avatar
    edhans
    2 years ago

    Sorry. I see the issue now. I had unnecessary table code in there. That column is being treated as an embedded table and it isn't. New code:

    let
        Source = Table.FromRows(Json.Document(Binary.Decompress(Binary.FromText("i45WMjDUByIjAyNjJR0lZ58gIOkIxAGleSWliTmZKYkpSrE6OJWFJBalJuJTEJRaUpRYnK/gmpValJyZnJmPqdg3yN2XGFuR1OGwFkkFkn2xAA==", BinaryEncoding.Base64), Compression.Deflate)), let _t = ((type nullable text) meta [Serialized.Text = true]) in type table [Fecha = _t, Alumno = _t, Materia = _t, Comentario = _t]),
        #"Changed Type" = Table.TransformColumnTypes(Source,{{"Fecha", type date}}),
        #"Grouped Rows" = 
            Table.Group(
                #"Changed Type", 
                {"Fecha", "Alumno", "Materia"}, 
                {
                    {"Comments", each Text.Combine(_[Comentario], ", ")
                    }
                }
            )
    in
        #"Grouped Rows"

     

    Basically you are removing the code below in yellow, including that first comma.