<?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: XML file Load to Delta table with different fields list in Data Engineering</title>
    <link>https://community.databricks.com/t5/data-engineering/xml-file-load-to-delta-table-with-different-fields-list/m-p/82689#M36719</link>
    <description>&lt;P&gt;The question is how to find the missing or new fields in nested XML files?&lt;/P&gt;</description>
    <pubDate>Mon, 12 Aug 2024 05:46:05 GMT</pubDate>
    <dc:creator>Atul-Kumar</dc:creator>
    <dc:date>2024-08-12T05:46:05Z</dc:date>
    <item>
      <title>XML file Load to Delta table with different fields list</title>
      <link>https://community.databricks.com/t5/data-engineering/xml-file-load-to-delta-table-with-different-fields-list/m-p/82678#M36714</link>
      <description>&lt;P&gt;I there,&lt;/P&gt;&lt;P&gt;I have a scenario where the source XML files may have all the fields or may be 80% of fields in next run. How to we load the files in Delta tables which should handle the XML files with all field lists and also with few fields only.&amp;nbsp;&lt;/P&gt;&lt;P&gt;In smaller field list, the problem is MERGE operation is failing as no of rows are not matching between source and target table.&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="atulkumar_0-1723433363042.png" style="width: 400px;"&gt;&lt;img src="https://community.databricks.com/t5/image/serverpage/image-id/10297i1988FFED072F56F8/image-size/medium/is-moderation-mode/true?v=v2&amp;amp;px=400" role="button" title="atulkumar_0-1723433363042.png" alt="atulkumar_0-1723433363042.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Any suggestion ?&lt;/P&gt;</description>
      <pubDate>Mon, 12 Aug 2024 03:29:39 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/xml-file-load-to-delta-table-with-different-fields-list/m-p/82678#M36714</guid>
      <dc:creator>Atul-Kumar</dc:creator>
      <dc:date>2024-08-12T03:29:39Z</dc:date>
    </item>
    <item>
      <title>Re: XML file Load to Delta table with different fields list</title>
      <link>https://community.databricks.com/t5/data-engineering/xml-file-load-to-delta-table-with-different-fields-list/m-p/82686#M36717</link>
      <description>&lt;P&gt;Hi Atul,&lt;/P&gt;&lt;P&gt;You can try to handle XML files with varying fields (based on multiple loads) when loading into Delta tables, ensure the Delta table can adapt to changes by enabling schema evolution. Fill in missing fields with default values (like NULL) before merging the data. This way, even if the XML file has fewer fields, the process will handle it smoothly without causing errors during the MERGE operation. Just a thought. Give a try.&lt;/P&gt;</description>
      <pubDate>Mon, 12 Aug 2024 05:03:31 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/xml-file-load-to-delta-table-with-different-fields-list/m-p/82686#M36717</guid>
      <dc:creator>Brahmareddy</dc:creator>
      <dc:date>2024-08-12T05:03:31Z</dc:date>
    </item>
    <item>
      <title>Re: XML file Load to Delta table with different fields list</title>
      <link>https://community.databricks.com/t5/data-engineering/xml-file-load-to-delta-table-with-different-fields-list/m-p/82689#M36719</link>
      <description>&lt;P&gt;The question is how to find the missing or new fields in nested XML files?&lt;/P&gt;</description>
      <pubDate>Mon, 12 Aug 2024 05:46:05 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/xml-file-load-to-delta-table-with-different-fields-list/m-p/82689#M36719</guid>
      <dc:creator>Atul-Kumar</dc:creator>
      <dc:date>2024-08-12T05:46:05Z</dc:date>
    </item>
    <item>
      <title>Re: XML file Load to Delta table with different fields list</title>
      <link>https://community.databricks.com/t5/data-engineering/xml-file-load-to-delta-table-with-different-fields-list/m-p/82704#M36722</link>
      <description>&lt;P&gt;&lt;a href="https://community.databricks.com/t5/user/viewprofilepage/user-id/115665"&gt;@Atul-Kumar&lt;/a&gt;&amp;nbsp;Have you tried to use the native XML support (introduced in DBR 14.3) with &lt;A href="https://docs.databricks.com/en/query/formats/xml.html#schema-inference-and-evolution-in-auto-loader" target="_self"&gt;Auto Loader&lt;/A&gt; + Rescue Data instead?&lt;/P&gt;</description>
      <pubDate>Mon, 12 Aug 2024 07:39:40 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/xml-file-load-to-delta-table-with-different-fields-list/m-p/82704#M36722</guid>
      <dc:creator>Witold</dc:creator>
      <dc:date>2024-08-12T07:39:40Z</dc:date>
    </item>
    <item>
      <title>Re: XML file Load to Delta table with different fields list</title>
      <link>https://community.databricks.com/t5/data-engineering/xml-file-load-to-delta-table-with-different-fields-list/m-p/84181#M37153</link>
      <description>&lt;P&gt;Auto Loader is not acceptable solution in my case. I tried to make an empty table using XSD file and then load the data frame. Some how it worked to meet the objective.&lt;/P&gt;</description>
      <pubDate>Mon, 26 Aug 2024 06:04:33 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/xml-file-load-to-delta-table-with-different-fields-list/m-p/84181#M37153</guid>
      <dc:creator>Atul-Kumar</dc:creator>
      <dc:date>2024-08-26T06:04:33Z</dc:date>
    </item>
  </channel>
</rss>

