<?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 Dataflow to lakehouse, bulk change header to appropriate format in Dataflow</title>
    <link>https://community.fabric.microsoft.com/t5/Dataflow/Dataflow-to-lakehouse-bulk-change-header-to-appropriate-format/m-p/3256163#M154</link>
    <description>&lt;P&gt;In my scenario, many current data source table has space in the header name. I understand that when loading data to Lakehouse, table header can not have space in it. Is there a way to bulk fill the header space? Or any other function that can change header to appropriate format?&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Fri, 09 Jun 2023 03:02:28 GMT</pubDate>
    <dc:creator>suidino2</dc:creator>
    <dc:date>2023-06-09T03:02:28Z</dc:date>
    <item>
      <title>Dataflow to lakehouse, bulk change header to appropriate format</title>
      <link>https://community.fabric.microsoft.com/t5/Dataflow/Dataflow-to-lakehouse-bulk-change-header-to-appropriate-format/m-p/3256163#M154</link>
      <description>&lt;P&gt;In my scenario, many current data source table has space in the header name. I understand that when loading data to Lakehouse, table header can not have space in it. Is there a way to bulk fill the header space? Or any other function that can change header to appropriate format?&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 09 Jun 2023 03:02:28 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Dataflow/Dataflow-to-lakehouse-bulk-change-header-to-appropriate-format/m-p/3256163#M154</guid>
      <dc:creator>suidino2</dc:creator>
      <dc:date>2023-06-09T03:02:28Z</dc:date>
    </item>
    <item>
      <title>Re: Dataflow to lakehouse, bulk change header to appropriate format</title>
      <link>https://community.fabric.microsoft.com/t5/Dataflow/Dataflow-to-lakehouse-bulk-change-header-to-appropriate-format/m-p/3256183#M155</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;There's a couple of things that you can do to tackle this.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;U&gt;&lt;STRONG&gt;The UI way&lt;/STRONG&gt;&lt;/U&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;Reference your query twice&amp;nbsp;&lt;img /&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;In both references make sure to demote the headers&amp;nbsp;&lt;img /&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;Let's say that one of the referenced queries will be called "Headers" and the other one will be "Data"&lt;UL&gt;&lt;LI&gt;&lt;STRONG&gt;For the Headers query:&lt;/STRONG&gt;&lt;UL&gt;&lt;LI&gt;Keep only the top 1 row&amp;nbsp;&lt;img /&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;Apply the "Replace values" transform to every single column in your query&amp;nbsp;&lt;img /&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;/LI&gt;&lt;LI&gt;&lt;STRONG&gt;For the Data query:&lt;/STRONG&gt;&lt;UL&gt;&lt;LI&gt;Remove the top 1 row&amp;nbsp;&lt;img /&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;/LI&gt;&lt;LI&gt;Append the Headers and Data query in that exact order&amp;nbsp;&lt;img /&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;Promote the first row to be the headers of the column&amp;nbsp;&lt;img /&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;Remove the now top 1 row of the table&lt;/LI&gt;&lt;/UL&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The M script way requires you to first use &lt;A href="https://learn.microsoft.com/en-us/powerquery-m/table-columnnames" target="_self"&gt;Table.ColumnNames&lt;/A&gt; to get the list of columns of your table, then use a function like &lt;A href="https://learn.microsoft.com/en-us/powerquery-m/list-transform" target="_self"&gt;List.Transform&lt;/A&gt; to establish how you'd like to transform such list of columns and then the use those two pieces to pass the arguments required for the &lt;A href="https://learn.microsoft.com/en-us/powerquery-m/table-renamecolumns" target="_self"&gt;Table.RenameColumns&lt;/A&gt; function and perhaps using the &lt;A href="https://learn.microsoft.com/en-us/powerquery-m/list-zip" target="_self"&gt;List.Zip&lt;/A&gt; function to create that list of lists (of previous and new column names).&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Let us know if this helps!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 27 May 2023 05:07:29 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Dataflow/Dataflow-to-lakehouse-bulk-change-header-to-appropriate-format/m-p/3256183#M155</guid>
      <dc:creator>miguel</dc:creator>
      <dc:date>2023-05-27T05:07:29Z</dc:date>
    </item>
  </channel>
</rss>

