<?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: Schema enforcement from External Location in Data Governance</title>
    <link>https://community.databricks.com/t5/data-governance/schema-enforcement-from-external-location/m-p/59088#M1581</link>
    <description>&lt;P&gt;&lt;SPAN&gt;define columns when create table&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&lt;A href="https://community.databricks.com/t5/data-engineering/external-table-from-parquet-partition/td-p/24689" target="_self"&gt;https://community.databricks.com/t5/data-engineering/external-table-from-parquet-partition/td-p/24689&lt;/A&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;</description>
    <pubDate>Sat, 03 Feb 2024 03:33:43 GMT</pubDate>
    <dc:creator>feiyun0112</dc:creator>
    <dc:date>2024-02-03T03:33:43Z</dc:date>
    <item>
      <title>Schema enforcement from External Location</title>
      <link>https://community.databricks.com/t5/data-governance/schema-enforcement-from-external-location/m-p/59074#M1580</link>
      <description>&lt;P&gt;Hi,&amp;nbsp;&lt;BR /&gt;This might be a silly question to ask but is it possible to enforce schema on a table created from external location, I am trying to create a table from a s3 location and my command looks like this&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;DIV&gt;&lt;PRE&gt;query = &lt;SPAN&gt;"""CREATE TABLE IF NOT EXISTS {}&lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN&gt;           USING PARQUET &lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN&gt;           LOCATION '{}'"""&lt;/SPAN&gt;.format(raw_table&lt;SPAN&gt;,&lt;/SPAN&gt;s3_bucket_location)&lt;/PRE&gt;&lt;P&gt;but I am not happy with the schema it infers from the parquet, Is there a way I can enforce schema on this table by changing some column types ? I tried by add the&amp;nbsp;&lt;BR /&gt;options ( schema = &amp;lt;schema_definition&amp;gt; ) to the create command, that didnt work.&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;/DIV&gt;</description>
      <pubDate>Fri, 02 Feb 2024 18:18:22 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-governance/schema-enforcement-from-external-location/m-p/59074#M1580</guid>
      <dc:creator>Dp15</dc:creator>
      <dc:date>2024-02-02T18:18:22Z</dc:date>
    </item>
    <item>
      <title>Re: Schema enforcement from External Location</title>
      <link>https://community.databricks.com/t5/data-governance/schema-enforcement-from-external-location/m-p/59088#M1581</link>
      <description>&lt;P&gt;&lt;SPAN&gt;define columns when create table&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&lt;A href="https://community.databricks.com/t5/data-engineering/external-table-from-parquet-partition/td-p/24689" target="_self"&gt;https://community.databricks.com/t5/data-engineering/external-table-from-parquet-partition/td-p/24689&lt;/A&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Sat, 03 Feb 2024 03:33:43 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-governance/schema-enforcement-from-external-location/m-p/59088#M1581</guid>
      <dc:creator>feiyun0112</dc:creator>
      <dc:date>2024-02-03T03:33:43Z</dc:date>
    </item>
  </channel>
</rss>

