<?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: Delta table zero downtime in Get Started Discussions</title>
    <link>https://community.databricks.com/t5/get-started-discussions/delta-table-zero-downtime/m-p/153602#M11635</link>
    <description>&lt;P&gt;&lt;a href="https://community.databricks.com/t5/user/viewprofilepage/user-id/103795"&gt;@databrciks&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This situation is now elegantly solved using&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;STRONG&gt;Multi Table Transactions in Databricks.&lt;/STRONG&gt;&amp;nbsp;Wrap the Truncate &amp;amp; Load logic in an &lt;STRONG&gt;ATOMIC&lt;/STRONG&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;block and you can achieve beyond single table consistency. This ensures that even if you are performing a truncate and load, report readers see the version before it.&lt;/P&gt;&lt;P&gt;Reports will not encounter an empty table or a partial state. Reports will see the valid version after truncate &amp;amp; full load is done. If the load fails, the transaction rolls back automatically leaving the reports stable.&lt;/P&gt;&lt;P&gt;More details &lt;A href="https://community.databricks.com/t5/community-articles/databricks-multi-table-transactions-all-data-or-nothing/td-p/150846" target="_self"&gt;here&lt;/A&gt;&lt;/P&gt;</description>
    <pubDate>Tue, 07 Apr 2026 08:43:18 GMT</pubDate>
    <dc:creator>balajij8</dc:creator>
    <dc:date>2026-04-07T08:43:18Z</dc:date>
    <item>
      <title>Delta table zero downtime</title>
      <link>https://community.databricks.com/t5/get-started-discussions/delta-table-zero-downtime/m-p/153561#M11630</link>
      <description>&lt;P&gt;Hello Experts&lt;/P&gt;&lt;P&gt;How to load everyday full load to delta table(truncate and load). The reports are pointing to this table.&lt;/P&gt;&lt;P&gt;How to ensure the zero downtime while load is on.&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;</description>
      <pubDate>Mon, 06 Apr 2026 19:55:23 GMT</pubDate>
      <guid>https://community.databricks.com/t5/get-started-discussions/delta-table-zero-downtime/m-p/153561#M11630</guid>
      <dc:creator>databrciks</dc:creator>
      <dc:date>2026-04-06T19:55:23Z</dc:date>
    </item>
    <item>
      <title>Re: Delta table zero downtime</title>
      <link>https://community.databricks.com/t5/get-started-discussions/delta-table-zero-downtime/m-p/153584#M11632</link>
      <description>&lt;P&gt;&lt;a href="https://community.databricks.com/t5/user/viewprofilepage/user-id/103795"&gt;@databrciks&lt;/a&gt;&amp;nbsp;Load your new data into a staging table, then replace the target using CREATE OR REPLACE TABLE or INSERT OVERWRITE.&lt;BR /&gt;Delta Lake writes are &lt;STRONG&gt;atomic&lt;/STRONG&gt;, so reports keep reading the old data until the new load finishes. There is &lt;STRONG&gt;no downtime and no empty table window&lt;/STRONG&gt;. Once the load commits, all users automatically see the new data.&lt;/P&gt;</description>
      <pubDate>Tue, 07 Apr 2026 03:53:20 GMT</pubDate>
      <guid>https://community.databricks.com/t5/get-started-discussions/delta-table-zero-downtime/m-p/153584#M11632</guid>
      <dc:creator>Sumit_7</dc:creator>
      <dc:date>2026-04-07T03:53:20Z</dc:date>
    </item>
    <item>
      <title>Re: Delta table zero downtime</title>
      <link>https://community.databricks.com/t5/get-started-discussions/delta-table-zero-downtime/m-p/153602#M11635</link>
      <description>&lt;P&gt;&lt;a href="https://community.databricks.com/t5/user/viewprofilepage/user-id/103795"&gt;@databrciks&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This situation is now elegantly solved using&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;STRONG&gt;Multi Table Transactions in Databricks.&lt;/STRONG&gt;&amp;nbsp;Wrap the Truncate &amp;amp; Load logic in an &lt;STRONG&gt;ATOMIC&lt;/STRONG&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;block and you can achieve beyond single table consistency. This ensures that even if you are performing a truncate and load, report readers see the version before it.&lt;/P&gt;&lt;P&gt;Reports will not encounter an empty table or a partial state. Reports will see the valid version after truncate &amp;amp; full load is done. If the load fails, the transaction rolls back automatically leaving the reports stable.&lt;/P&gt;&lt;P&gt;More details &lt;A href="https://community.databricks.com/t5/community-articles/databricks-multi-table-transactions-all-data-or-nothing/td-p/150846" target="_self"&gt;here&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 07 Apr 2026 08:43:18 GMT</pubDate>
      <guid>https://community.databricks.com/t5/get-started-discussions/delta-table-zero-downtime/m-p/153602#M11635</guid>
      <dc:creator>balajij8</dc:creator>
      <dc:date>2026-04-07T08:43:18Z</dc:date>
    </item>
    <item>
      <title>Re: Delta table zero downtime</title>
      <link>https://community.databricks.com/t5/get-started-discussions/delta-table-zero-downtime/m-p/153603#M11636</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.databricks.com/t5/user/viewprofilepage/user-id/103795"&gt;@databrciks&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;You can achieve this in multiple ways, as shown below.. All of these patterns work. They&amp;nbsp;do a copy-on-write overwrite which means Databricks writes new files and then atomically commits a new table version. There is never a committed state where the table is empty. So, this is the safest option.&lt;/P&gt;
&lt;LI-CODE lang="python"&gt;(
  df  
  .write
  .format("delta")
  .mode("overwrite")          # full refresh
  .option("overwriteSchema", "true")   # only if schema can change
  .saveAsTable("prod.report_table")
)&lt;/LI-CODE&gt;&lt;LI-CODE lang="python"&gt;INSERT OVERWRITE TABLE prod.report_table
SELECT ...
FROM source_...;&lt;/LI-CODE&gt;&lt;LI-CODE lang="python"&gt;CREATE OR REPLACE TABLE prod.report_table AS
SELECT ...
FROM source_...;&lt;/LI-CODE&gt;
&lt;P&gt;What you don't want to be doing is truncate and load as shown below.&lt;/P&gt;
&lt;LI-CODE lang="python"&gt;TRUNCATE TABLE prod.report_table;
INSERT INTO prod.report_table SELECT ...;&lt;/LI-CODE&gt;
&lt;P&gt;This will be an anti-pattern because between TRUNCATE commit and INSERT commit, any new query sees an empty table.&lt;/P&gt;
&lt;P class="p1"&gt;&lt;FONT size="2" color="#FF6600"&gt;&lt;STRONG&gt;&lt;I&gt;If this answer resolves your question, could you mark it as “Accept as Solution”? That helps other users quickly find the correct fix.&lt;/I&gt;&lt;/STRONG&gt;&lt;/FONT&gt;&lt;I&gt;&lt;/I&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 07 Apr 2026 08:44:12 GMT</pubDate>
      <guid>https://community.databricks.com/t5/get-started-discussions/delta-table-zero-downtime/m-p/153603#M11636</guid>
      <dc:creator>Ashwin_DSA</dc:creator>
      <dc:date>2026-04-07T08:44:12Z</dc:date>
    </item>
  </channel>
</rss>

