<?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: Unity Catalog blocks DML (UPDATE, DELETE) on static Delta tables — unable to use spark.sql in Data Engineering</title>
    <link>https://community.databricks.com/t5/data-engineering/unity-catalog-blocks-dml-update-delete-on-static-delta-tables/m-p/123406#M46997</link>
    <description>&lt;P&gt;[RESOLVED] The issue was caused by the source tables being in Parquet format. After rewriting them as Delta tables, everything worked fine — including DML operations like UPDATE via DataFrame logic. Thanks!&lt;/P&gt;</description>
    <pubDate>Tue, 01 Jul 2025 08:43:01 GMT</pubDate>
    <dc:creator>varni</dc:creator>
    <dc:date>2025-07-01T08:43:01Z</dc:date>
    <item>
      <title>Unity Catalog blocks DML (UPDATE, DELETE) on static Delta tables — unable to use spark.sql</title>
      <link>https://community.databricks.com/t5/data-engineering/unity-catalog-blocks-dml-update-delete-on-static-delta-tables/m-p/123399#M46995</link>
      <description>&lt;P&gt;&lt;SPAN&gt;Hello,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;We’ve started migrating from Azure Databricks (Hive Metastore) to AWS Databricks with Unity Catalog. Our entire codebase was deliberately designed around &lt;/SPAN&gt;&lt;SPAN&gt;spark.sql('...')&lt;/SPAN&gt;&lt;SPAN&gt; using DML operations (&lt;/SPAN&gt;&lt;SPAN&gt;UPDATE&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;DELETE&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;MERGE&lt;/SPAN&gt;&lt;SPAN&gt;) for two reasons:&lt;/SPAN&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;&lt;P&gt;&lt;SPAN&gt;In many cases, performing &lt;/SPAN&gt;&lt;SPAN&gt;UPDATE&lt;/SPAN&gt;&lt;SPAN&gt; through a DataFrame took tens of minutes (e.g. updating 100 rows could take up to 30 minutes), while the same operation via &lt;/SPAN&gt;&lt;SPAN&gt;spark.sql&lt;/SPAN&gt;&lt;SPAN&gt; completed in seconds.&lt;/SPAN&gt;&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;&lt;SPAN&gt;SQL-based logic significantly improves readability and flexibility, especially when collaborating with analysts who are not proficient in PySpark.&lt;/SPAN&gt;&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;SPAN&gt;&lt;STRONG&gt;Problem:&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;After migrating to Unity Catalog, all &lt;/SPAN&gt;&lt;SPAN&gt;spark.sql('UPDATE ...')&lt;/SPAN&gt;&lt;SPAN&gt; calls on static Delta tables now fail with:&lt;/SPAN&gt;&lt;/P&gt;&lt;PRE&gt;&lt;SPAN&gt;[UC_COMMAND_NOT_SUPPORTED.WITHOUT_RECOMMENDATION] UpdateTable are not supported in Unity Catalog.&lt;/SPAN&gt;&lt;/PRE&gt;&lt;P&gt;&lt;SPAN&gt;What’s worse is that the error explicitly states &lt;/SPAN&gt;&lt;SPAN&gt;&lt;STRONG&gt;no alternative or workaround is provided&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;SPAN&gt;.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&lt;STRONG&gt;Current options we see:&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;OL&gt;&lt;LI&gt;&lt;P&gt;&lt;SPAN&gt;Rewrite all SQL logic to use DataFrame API — which is expensive and undermines the original design and performance.&lt;/SPAN&gt;&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;&lt;SPAN&gt;Stay on Hive Metastore and forgo Unity Catalog — losing key features like audit logging, fine-grained ACLs, lineage, and external catalogs.&lt;/SPAN&gt;&lt;/P&gt;&lt;/LI&gt;&lt;/OL&gt;&lt;P&gt;&lt;SPAN&gt;&lt;STRONG&gt;Questions:&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;&lt;P&gt;&lt;SPAN&gt;Is support for &lt;/SPAN&gt;&lt;SPAN&gt;UPDATE&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;DELETE&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;MERGE&lt;/SPAN&gt;&lt;SPAN&gt; on static Delta tables planned in Unity Catalog?&lt;/SPAN&gt;&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;&lt;SPAN&gt;Is there any officially supported way to retain SQL-based DML compatibility under Unity Catalog?&lt;/SPAN&gt;&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;&lt;SPAN&gt;Are there any planned mechanisms for SQL migration to Unity Catalog without completely switching to DataFrame logic?&lt;/SPAN&gt;&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;SPAN&gt;Thank you!&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 01 Jul 2025 07:45:27 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/unity-catalog-blocks-dml-update-delete-on-static-delta-tables/m-p/123399#M46995</guid>
      <dc:creator>varni</dc:creator>
      <dc:date>2025-07-01T07:45:27Z</dc:date>
    </item>
    <item>
      <title>Re: Unity Catalog blocks DML (UPDATE, DELETE) on static Delta tables — unable to use spark.sql</title>
      <link>https://community.databricks.com/t5/data-engineering/unity-catalog-blocks-dml-update-delete-on-static-delta-tables/m-p/123406#M46997</link>
      <description>&lt;P&gt;[RESOLVED] The issue was caused by the source tables being in Parquet format. After rewriting them as Delta tables, everything worked fine — including DML operations like UPDATE via DataFrame logic. Thanks!&lt;/P&gt;</description>
      <pubDate>Tue, 01 Jul 2025 08:43:01 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/unity-catalog-blocks-dml-update-delete-on-static-delta-tables/m-p/123406#M46997</guid>
      <dc:creator>varni</dc:creator>
      <dc:date>2025-07-01T08:43:01Z</dc:date>
    </item>
    <item>
      <title>Re: Unity Catalog blocks DML (UPDATE, DELETE) on static Delta tables — unable to use spark.sql</title>
      <link>https://community.databricks.com/t5/data-engineering/unity-catalog-blocks-dml-update-delete-on-static-delta-tables/m-p/123421#M47005</link>
      <description>&lt;P&gt;Just to clarify: Delta tables still store data in Parquet under the hood, but Delta adds a transaction log (_delta_log) that enables ACID operations like UPDATE, DELETE, and MERGE.&lt;/P&gt;&lt;P&gt;That log layer is what Unity Catalog expects for full SQL DML support — which explains why converting the tables to Delta resolved the issue.&lt;/P&gt;&lt;P&gt;Thanks for sharing the resolution! It will help others hitting the same blocker.&lt;/P&gt;&lt;P&gt;In case it's useful to someone, here are the commands:&lt;BR /&gt;Convert existing Parquet folder to Delta:&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;CONVERT TO DELTA parquet.`s3://your-bucket/path/to/parquet-data`&lt;/LI-CODE&gt;&lt;P&gt;Convert existing external table to Delta:&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;CONVERT TO DELTA your_schema.your_parquet_table&lt;/LI-CODE&gt;&lt;P&gt;Create a Delta table directly:&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;CREATE TABLE your_table
USING DELTA
LOCATION 's3://your-bucket/path'&lt;/LI-CODE&gt;&lt;P&gt;Greetings!!!!!&lt;/P&gt;</description>
      <pubDate>Tue, 01 Jul 2025 11:07:10 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/unity-catalog-blocks-dml-update-delete-on-static-delta-tables/m-p/123421#M47005</guid>
      <dc:creator>HLEGUA</dc:creator>
      <dc:date>2025-07-01T11:07:10Z</dc:date>
    </item>
  </channel>
</rss>

