Forum Discussion

TimTeska's avatar
TimTeska
Frequent Visitor
2 years ago
Solved

Creating a new column using the contents from another cell.

Hello Experts, I'm having trouble with something I think should be very straight forward. I am new to Power Query Editor and still learning DAX, M and I have no experience with JSON. During a load ...
  • dufoq3's avatar
    2 years ago

    Hi TimTeska,
    you can't call value from another row directly (there are of course ways how to do it), but you can call line from previous step

    Source (previous step):

    Added custom column:

  • Anonymous's avatar
    Anonymous
    2 years ago

    Hi TimTeska ,

    Please try:

    Text.BeforeDelimiter(#"Changed Type"{3}[Column1],",")

    Advanced editor:

    let
        Source = Table.FromRows(Json.Document(Binary.Decompress(Binary.FromText("i45WMjTSN9M3MjAyVjA0tzI2UtJRQkGxOtFKjk7OCs75uQWJeZXYpINLk5zz84rzczJTEktSUxSCS3NzE4sqFYJSC/KLShQ0IHRmXromNt0gq+Odc/KLU+MDDXUUnIMNDAyM4oNS0zPz8+K98rwU3B0dAzA0xgIA", BinaryEncoding.Base64), Compression.Deflate)), let _t = ((type nullable text) meta [Serialized.Text = true]) in type table [Column1 = _t, Column2 = _t, Column3 = _t, Column4 = _t, Column5 = _t, Column6 = _t]),
        #"Changed Type" = Table.TransformColumnTypes(Source,{{"Column1", type text}, {"Column2", type text}, {"Column3", type text}, {"Column4", type text}, {"Column5", type text}, {"Column6", type text}}),
        #"Added Custom" = Table.AddColumn(#"Changed Type", "Period", each Text.BeforeDelimiter(#"Changed Type"{3}[Column1],","))
    in
        #"Added Custom"

    Best Regards,
    Gao

    Community Support Team

     

    If there is any post helps, then please consider Accept it as the solution  to help the other members find it more quickly.
    If I misunderstand your needs or you still have problems on it, please feel free to let us know. Thanks a lot!

    How to get your questions answered quickly --  How to provide sample data in the Power BI Forum -- China Power BI User Group