<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Column Splitting in Power Query</title>
    <link>https://community.fabric.microsoft.com/t5/Power-Query/Column-Splitting/m-p/2827726#M87828</link>
    <description>&lt;P&gt;split by '_' (once, as far left as possible). That should give 2 columns,&lt;/P&gt;
&lt;P&gt;then split the 2nd column in the same way&lt;/P&gt;</description>
    <pubDate>Sat, 08 Oct 2022 22:58:54 GMT</pubDate>
    <dc:creator>HotChilli</dc:creator>
    <dc:date>2022-10-08T22:58:54Z</dc:date>
    <item>
      <title>Column Splitting</title>
      <link>https://community.fabric.microsoft.com/t5/Power-Query/Column-Splitting/m-p/2827702#M87825</link>
      <description>&lt;P&gt;My column has data like&lt;/P&gt;&lt;P&gt;75_Bear_IMG_34567.jpg&lt;/P&gt;&lt;P&gt;76_Bobcat_08070203.jpg&lt;/P&gt;&lt;P&gt;77_Racoon_IMG_55555.jpg&lt;/P&gt;&lt;P&gt;I want to split into three columns.&amp;nbsp;A location number, a specie and an image name. These three species are examples. Specie name could be 3 to 10 characters&lt;/P&gt;&lt;P&gt;75 Bear IMG_34567.jpg&lt;/P&gt;&lt;P&gt;76 Bobcat 08070203.jpg&lt;/P&gt;&lt;P&gt;77 Racoon IMG_55555.jpg&lt;/P&gt;&lt;P&gt;I see how to split the first two digits, but haven't found how to split the rest. I have tried using underscore as a custom delimiter but that hasn't worked. I have searched the docts and don't see how any of the 7 suggested methods apply.&amp;nbsp;&lt;/P&gt;&lt;P&gt;If I can delete the first 2 unscores, then I probably could use lower case to upper case and nondigit to digit.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Is there a better way?&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 08 Oct 2022 22:24:28 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Power-Query/Column-Splitting/m-p/2827702#M87825</guid>
      <dc:creator>lutolfr</dc:creator>
      <dc:date>2022-10-08T22:24:28Z</dc:date>
    </item>
    <item>
      <title>Re: Column Splitting</title>
      <link>https://community.fabric.microsoft.com/t5/Power-Query/Column-Splitting/m-p/2827718#M87826</link>
      <description>&lt;LI-CODE lang="markup"&gt;let
    Source = Table.FromRows(Json.Document(Binary.Decompress(Binary.FromText(
        "i45WMjeNd0pNLIr39HWPNzYxNTPXyypIV4rVAcqYxTvlJyUnlsQbWBiYGxgZGCOkzOODEpPz8/PA2kxBACIXCwA=", BinaryEncoding.Base64), Compression.Deflate))),
    lst = List.Transform(Source[Column1], each let t = Text.Split(_, "_") in List.FirstN(t,2) &amp;amp; {Text.Combine(List.Skip(t,2), "_")}),
    Result = Table.FromRows(lst, {"Location","Species", "Image Name"})
in
    Result&lt;/LI-CODE&gt;</description>
      <pubDate>Sat, 08 Oct 2022 22:55:54 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Power-Query/Column-Splitting/m-p/2827718#M87826</guid>
      <dc:creator>jgordon11</dc:creator>
      <dc:date>2022-10-08T22:55:54Z</dc:date>
    </item>
    <item>
      <title>Re: Column Splitting</title>
      <link>https://community.fabric.microsoft.com/t5/Power-Query/Column-Splitting/m-p/2827726#M87828</link>
      <description>&lt;P&gt;split by '_' (once, as far left as possible). That should give 2 columns,&lt;/P&gt;
&lt;P&gt;then split the 2nd column in the same way&lt;/P&gt;</description>
      <pubDate>Sat, 08 Oct 2022 22:58:54 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Power-Query/Column-Splitting/m-p/2827726#M87828</guid>
      <dc:creator>HotChilli</dc:creator>
      <dc:date>2022-10-08T22:58:54Z</dc:date>
    </item>
    <item>
      <title>Re: Column Splitting</title>
      <link>https://community.fabric.microsoft.com/t5/Power-Query/Column-Splitting/m-p/2827731#M87830</link>
      <description>&lt;P class="lia-align-justify"&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="451623" data-lia-user-login="lutolfr" class="lia-mention lia-mention-user"&gt;lutolfr&lt;/a&gt;,&lt;/P&gt;&lt;P class="lia-align-justify"&gt;&amp;nbsp;&lt;/P&gt;&lt;P class="lia-align-justify"&gt;You can use list functions to convert the text into a list, for the location number and species, you can just read the first and second element of the list. For image name, you'll be choosing everything after the species name.&lt;/P&gt;&lt;P class="lia-align-justify"&gt;&amp;nbsp;&lt;/P&gt;&lt;P class="lia-align-justify"&gt;Here's how you can do it:&lt;/P&gt;&lt;P class="lia-align-justify"&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="java"&gt;let
    Source = Table.FromRows(Json.Document(Binary.Decompress(Binary.FromText("i45WMjeNd0pNLIr39HWPNzYxNTPXyypIV4rVAcqYxTvlJyUnlsQbWBiYGxgZGCOkzOODEpPz8/PA2kxBACIXCwA=", BinaryEncoding.Base64), Compression.Deflate)), let _t = ((type nullable text) meta [Serialized.Text = true]) in type table [Values = _t]),
    #"Changed Type" = Table.TransformColumnTypes(Source,{{"Values", type text}}),
    #"Added Custom" = Table.AddColumn(#"Changed Type", "Location Number", each Text.Split([Values],"_"){0}),
    #"Added Custom1" = Table.AddColumn(#"Added Custom", "Species", each Text.Split([Values],"_"){1}),
    #"Added Custom2" = Table.AddColumn(#"Added Custom1", "Image Name", each List.Range(Text.Split([Values],"_"),2)),
    #"Extracted Values" = Table.TransformColumns(#"Added Custom2", {"Image Name", each Text.Combine(List.Transform(_, Text.From), "_"), type text})
in
    #"Extracted Values"&lt;/LI-CODE&gt;&lt;P class="lia-align-justify"&gt;&amp;nbsp;&lt;/P&gt;&lt;P class="lia-align-justify"&gt;Result:&lt;/P&gt;&lt;P class="lia-align-justify"&gt;&amp;nbsp;&lt;/P&gt;&lt;P class="lia-align-justify"&gt;&lt;img /&gt;&lt;/P&gt;&lt;P class="lia-align-justify"&gt;&amp;nbsp;&lt;/P&gt;&lt;P class="lia-align-justify"&gt;&lt;EM&gt;Works for you? Mark this post as a solution if it does!&lt;/EM&gt;&lt;/P&gt;</description>
      <pubDate>Sat, 08 Oct 2022 23:02:33 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Power-Query/Column-Splitting/m-p/2827731#M87830</guid>
      <dc:creator>Shaurya</dc:creator>
      <dc:date>2022-10-08T23:02:33Z</dc:date>
    </item>
    <item>
      <title>Re: Column Splitting</title>
      <link>https://community.fabric.microsoft.com/t5/Power-Query/Column-Splitting/m-p/2827749#M87834</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;you can:&lt;/P&gt;
&lt;P&gt;- first duplicate your column&lt;/P&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;- then Split column by delimiter on the duplicate column&lt;/P&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;an finally in Add column Extract text after delimiter on the original column&lt;/P&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;and you obtain this&lt;/P&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;If this post is useful to help you to solve your issue consider giving the post a thumbs up&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;and accepting it as a solution !&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 08 Oct 2022 23:10:16 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Power-Query/Column-Splitting/m-p/2827749#M87834</guid>
      <dc:creator>serpiva64</dc:creator>
      <dc:date>2022-10-08T23:10:16Z</dc:date>
    </item>
    <item>
      <title>Re: Column Splitting</title>
      <link>https://community.fabric.microsoft.com/t5/Power-Query/Column-Splitting/m-p/2829167#M87871</link>
      <description>&lt;P&gt;I tried this solution first because fewer steps. I also tried&amp;nbsp;&lt;A href="https://community.powerbi.com/t5/user/viewprofilepage/user-id/96253" target="_self"&gt;&lt;SPAN class=""&gt;serpiva64&lt;/SPAN&gt;&lt;/A&gt;&amp;nbsp;and&amp;nbsp;&lt;A href="https://community.powerbi.com/t5/user/viewprofilepage/user-id/450074" target="_self"&gt;&lt;SPAN class=""&gt;Shaurya&lt;/SPAN&gt;&lt;/A&gt;&lt;SPAN&gt;&amp;nbsp;and they worked. I also learned stuff from the others but didn't try to confirm that they worked. So thanks everyone.&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Sun, 09 Oct 2022 16:45:55 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Power-Query/Column-Splitting/m-p/2829167#M87871</guid>
      <dc:creator>lutolfr</dc:creator>
      <dc:date>2022-10-09T16:45:55Z</dc:date>
    </item>
  </channel>
</rss>

