<?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: REPLACE TABLE AS SELECT is not working with parquet whereas it works fine for delta in Data Engineering</title>
    <link>https://community.databricks.com/t5/data-engineering/replace-table-as-select-is-not-working-with-parquet-whereas-it/m-p/59683#M31479</link>
    <description>&lt;P&gt;Hi Kaniz, I wanted to know why this is happening. I know how to avoid this. Could you please help in understanding the error and its cause?&lt;/P&gt;</description>
    <pubDate>Thu, 08 Feb 2024 11:45:34 GMT</pubDate>
    <dc:creator>Dhruv-22</dc:creator>
    <dc:date>2024-02-08T11:45:34Z</dc:date>
    <item>
      <title>REPLACE TABLE AS SELECT is not working with parquet whereas it works fine for delta</title>
      <link>https://community.databricks.com/t5/data-engineering/replace-table-as-select-is-not-working-with-parquet-whereas-it/m-p/59666#M31467</link>
      <description>&lt;P&gt;I am working on Azure Databricks, with Databricks Runtime version being -&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;FONT color="#993300"&gt;14.3 LTS (includes Apache Spark 3.5.0, Scala 2.12)&lt;/FONT&gt;. I am facing the following issue.&lt;/P&gt;&lt;P&gt;Suppose I have a view named&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;FONT color="#993300"&gt;v1&lt;/FONT&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;and a database&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;FONT color="#993300"&gt;f1_processed&lt;/FONT&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;created from the following command&lt;/P&gt;&lt;PRE&gt;&lt;SPAN class=""&gt;CREATE&lt;/SPAN&gt; DATABASE IF &lt;SPAN class=""&gt;NOT&lt;/SPAN&gt; &lt;SPAN class=""&gt;EXISTS&lt;/SPAN&gt; f1_processed
LOCATION "abfss://processed@formula1dl679student.dfs.core.windows.net/"&lt;/PRE&gt;&lt;P&gt;Then if I run the following command it runs fine.&lt;/P&gt;&lt;PRE&gt;&lt;SPAN class=""&gt;CREATE&lt;/SPAN&gt; &lt;SPAN class=""&gt;OR&lt;/SPAN&gt; REPLACE &lt;SPAN class=""&gt;TABLE&lt;/SPAN&gt; f1_processed.circuits
&lt;SPAN class=""&gt;AS&lt;/SPAN&gt;
&lt;SPAN class=""&gt;SELECT&lt;/SPAN&gt; &lt;SPAN class=""&gt;*&lt;/SPAN&gt; &lt;SPAN class=""&gt;FROM&lt;/SPAN&gt; v1;&lt;/PRE&gt;&lt;P&gt;However, if I specify the format like in the following code&lt;/P&gt;&lt;PRE&gt;&lt;SPAN class=""&gt;CREATE&lt;/SPAN&gt; &lt;SPAN class=""&gt;OR&lt;/SPAN&gt; REPLACE &lt;SPAN class=""&gt;TABLE&lt;/SPAN&gt; f1_processed.circuits
&lt;SPAN class=""&gt;USING&lt;/SPAN&gt; PARQUET
&lt;SPAN class=""&gt;AS&lt;/SPAN&gt;
&lt;SPAN class=""&gt;SELECT&lt;/SPAN&gt; &lt;SPAN class=""&gt;*&lt;/SPAN&gt; &lt;SPAN class=""&gt;FROM&lt;/SPAN&gt; v1;&lt;/PRE&gt;&lt;P&gt;An error is thrown&lt;/P&gt;&lt;PRE&gt;[UNSUPPORTED_FEATURE.TABLE_OPERATION] The feature is not supported: 
Table `spark_catalog`.`f1_processed`.`circuits` does not support REPLACE TABLE AS SELECT. 
Please check the current catalog and namespace to make sure the qualified table name is expected, 
and also check the catalog implementation which is configured by "spark.sql.catalog". SQLSTATE: 0A000&lt;/PRE&gt;&lt;P&gt;As seen from the first command, REPLACE TABLE AS SELECT is supported and the error is wrong. Any help is appreciated.&lt;/P&gt;</description>
      <pubDate>Thu, 08 Feb 2024 09:28:13 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/replace-table-as-select-is-not-working-with-parquet-whereas-it/m-p/59666#M31467</guid>
      <dc:creator>Dhruv-22</dc:creator>
      <dc:date>2024-02-08T09:28:13Z</dc:date>
    </item>
    <item>
      <title>Re: REPLACE TABLE AS SELECT is not working with parquet whereas it works fine for delta</title>
      <link>https://community.databricks.com/t5/data-engineering/replace-table-as-select-is-not-working-with-parquet-whereas-it/m-p/59683#M31479</link>
      <description>&lt;P&gt;Hi Kaniz, I wanted to know why this is happening. I know how to avoid this. Could you please help in understanding the error and its cause?&lt;/P&gt;</description>
      <pubDate>Thu, 08 Feb 2024 11:45:34 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/replace-table-as-select-is-not-working-with-parquet-whereas-it/m-p/59683#M31479</guid>
      <dc:creator>Dhruv-22</dc:creator>
      <dc:date>2024-02-08T11:45:34Z</dc:date>
    </item>
    <item>
      <title>Re: REPLACE TABLE AS SELECT is not working with parquet whereas it works fine for delta</title>
      <link>https://community.databricks.com/t5/data-engineering/replace-table-as-select-is-not-working-with-parquet-whereas-it/m-p/59709#M31495</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.databricks.com/t5/user/viewprofilepage/user-id/99515"&gt;@Dhruv-22&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;We understand that you are facing the following error when using REPLACE TABLE AS SELECT&amp;nbsp; on the Parquet Table but at this moment&amp;nbsp;the REPLACE TABLE AS SELECT operation you're trying to perform is not supported for Parquet tables.&lt;/P&gt;
&lt;P&gt;According to our documentation, the REPLACE clause is only supported for Delta Lake tables. If you're working with Parquet, you might need to consider converting your tables to Delta format to use this feature.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Please refer to this document:&amp;nbsp;&lt;A href="https://docs.databricks.com/en/sql/language-manual/sql-ref-syntax-ddl-create-table-using.html#:~:text=Parameters-,REPLACE,-If%20specified%20replaces" target="_blank"&gt;https://docs.databricks.com/en/sql/language-manual/sql-ref-syntax-ddl-create-table-using.html#:~:text=Parameters-,REPLACE,-If%20specified%20replaces&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;Please let me know if this helps and leave a like if this helps, followups are appreciated.&lt;BR /&gt;Kudos&lt;BR /&gt;Ayushi&lt;/P&gt;</description>
      <pubDate>Thu, 08 Feb 2024 14:23:19 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/replace-table-as-select-is-not-working-with-parquet-whereas-it/m-p/59709#M31495</guid>
      <dc:creator>Ayushi_Suthar</dc:creator>
      <dc:date>2024-02-08T14:23:19Z</dc:date>
    </item>
    <item>
      <title>Re: REPLACE TABLE AS SELECT is not working with parquet whereas it works fine for delta</title>
      <link>https://community.databricks.com/t5/data-engineering/replace-table-as-select-is-not-working-with-parquet-whereas-it/m-p/59716#M31497</link>
      <description>&lt;P&gt;Thanks for the answer&lt;/P&gt;</description>
      <pubDate>Thu, 08 Feb 2024 16:42:08 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/replace-table-as-select-is-not-working-with-parquet-whereas-it/m-p/59716#M31497</guid>
      <dc:creator>Dhruv-22</dc:creator>
      <dc:date>2024-02-08T16:42:08Z</dc:date>
    </item>
  </channel>
</rss>

