<?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 Refresh a External table metadata in Data Governance</title>
    <link>https://community.databricks.com/t5/data-governance/refresh-a-external-table-metadata/m-p/57604#M1546</link>
    <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I have an external table which is created out of a S3 bucket. The first time I am creating the table I am using the following command :&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;query &lt;/SPAN&gt;&lt;SPAN&gt;=&lt;/SPAN&gt; &lt;SPAN&gt;"""&lt;/SPAN&gt;&lt;SPAN&gt;CREATE TABLE IF NOT EXISTS catalog.schema.external_table_s3&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;USING PARQUET &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;LOCATION '&lt;/SPAN&gt;&lt;SPAN&gt;{}&lt;/SPAN&gt;&lt;SPAN&gt;'&lt;/SPAN&gt;&lt;SPAN&gt;"""&lt;/SPAN&gt;&lt;SPAN&gt;.&lt;/SPAN&gt;&lt;SPAN&gt;format&lt;/SPAN&gt;&lt;SPAN&gt;(bucket_location)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&lt;SPAN&gt;The first time the table is created the files in the 'bucket_location' are loaded into the table. Now, I have a use case where when new files are added in the S3, I would like the metadata of this external table to be refreshed. Is it possible to refresh the metadata of the external table? I tried using the MSCK Repair command&amp;nbsp;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&lt;SPAN&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;MSCK REPAIR &lt;/SPAN&gt;&lt;SPAN&gt;TABLE&lt;/SPAN&gt;&amp;nbsp;&lt;SPAN&gt;catalog.schema.external_table_s3&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;SPAN&gt;&lt;BR /&gt;but my command failed with the following error:&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;AnalysisException: [UC_COMMAND_NOT_SUPPORTED.WITHOUT_RECOMMENDATION] The command(s): Repair Table are not supported in Unity Catalog. ;&lt;BR /&gt;RepairTableCommand catalog.schema.external_table_s3, true, false, MSCK REPAIR TABLE&lt;BR /&gt;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;/DIV&gt;</description>
    <pubDate>Wed, 17 Jan 2024 15:44:48 GMT</pubDate>
    <dc:creator>Dp15</dc:creator>
    <dc:date>2024-01-17T15:44:48Z</dc:date>
    <item>
      <title>Refresh a External table metadata</title>
      <link>https://community.databricks.com/t5/data-governance/refresh-a-external-table-metadata/m-p/57604#M1546</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I have an external table which is created out of a S3 bucket. The first time I am creating the table I am using the following command :&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;query &lt;/SPAN&gt;&lt;SPAN&gt;=&lt;/SPAN&gt; &lt;SPAN&gt;"""&lt;/SPAN&gt;&lt;SPAN&gt;CREATE TABLE IF NOT EXISTS catalog.schema.external_table_s3&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;USING PARQUET &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;LOCATION '&lt;/SPAN&gt;&lt;SPAN&gt;{}&lt;/SPAN&gt;&lt;SPAN&gt;'&lt;/SPAN&gt;&lt;SPAN&gt;"""&lt;/SPAN&gt;&lt;SPAN&gt;.&lt;/SPAN&gt;&lt;SPAN&gt;format&lt;/SPAN&gt;&lt;SPAN&gt;(bucket_location)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&lt;SPAN&gt;The first time the table is created the files in the 'bucket_location' are loaded into the table. Now, I have a use case where when new files are added in the S3, I would like the metadata of this external table to be refreshed. Is it possible to refresh the metadata of the external table? I tried using the MSCK Repair command&amp;nbsp;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&lt;SPAN&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;MSCK REPAIR &lt;/SPAN&gt;&lt;SPAN&gt;TABLE&lt;/SPAN&gt;&amp;nbsp;&lt;SPAN&gt;catalog.schema.external_table_s3&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;SPAN&gt;&lt;BR /&gt;but my command failed with the following error:&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;AnalysisException: [UC_COMMAND_NOT_SUPPORTED.WITHOUT_RECOMMENDATION] The command(s): Repair Table are not supported in Unity Catalog. ;&lt;BR /&gt;RepairTableCommand catalog.schema.external_table_s3, true, false, MSCK REPAIR TABLE&lt;BR /&gt;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;/DIV&gt;</description>
      <pubDate>Wed, 17 Jan 2024 15:44:48 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-governance/refresh-a-external-table-metadata/m-p/57604#M1546</guid>
      <dc:creator>Dp15</dc:creator>
      <dc:date>2024-01-17T15:44:48Z</dc:date>
    </item>
    <item>
      <title>Re: Refresh a External table metadata</title>
      <link>https://community.databricks.com/t5/data-governance/refresh-a-external-table-metadata/m-p/57609#M1548</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.databricks.com/t5/user/viewprofilepage/user-id/9"&gt;@Retired_mod&lt;/a&gt;&amp;nbsp;thank you for reply, how can we handle the schema changes in the external location, what if there are additions or deletions on the schema, will the refresh table work then too?&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 17 Jan 2024 16:43:45 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-governance/refresh-a-external-table-metadata/m-p/57609#M1548</guid>
      <dc:creator>Dp15</dc:creator>
      <dc:date>2024-01-17T16:43:45Z</dc:date>
    </item>
    <item>
      <title>Re: Refresh a External table metadata</title>
      <link>https://community.databricks.com/t5/data-governance/refresh-a-external-table-metadata/m-p/102311#M2323</link>
      <description>&lt;P&gt;Please try&amp;nbsp;&lt;A href="https://docs.databricks.com/en/tables/external-partition-discovery.html" target="_self"&gt;partition discovery for external tables&lt;/A&gt;. This feature should make it so that you can successfully run the MSCK REPAIR command, and more importantly, query external Parquet tables in a more performant way.&lt;/P&gt;</description>
      <pubDate>Mon, 16 Dec 2024 22:16:45 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-governance/refresh-a-external-table-metadata/m-p/102311#M2323</guid>
      <dc:creator>cgrant</dc:creator>
      <dc:date>2024-12-16T22:16:45Z</dc:date>
    </item>
  </channel>
</rss>

