<?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 Sync table A to table B, triggered by any change in table A. in Data Engineering</title>
    <link>https://community.databricks.com/t5/data-engineering/sync-table-a-to-table-b-triggered-by-any-change-in-table-a/m-p/92946#M38589</link>
    <description>&lt;P&gt;Hey,&lt;/P&gt;&lt;P&gt;I'm trying to find a way to sync table A to table B whenever table A is written to.&amp;nbsp;just with a trigger on write.&lt;BR /&gt;I want to avoid using any continuous runs or schedules.&lt;BR /&gt;Trying to get this to work inside Databricks, without having to use any outside listeners/triggers.&lt;/P&gt;&lt;P&gt;I tried looking into using a workflow that's triggered by new files in a volume - but I couldn't create a volume that is on the same location of the table I want to monitor.&lt;/P&gt;&lt;P&gt;What is the way to achieve this?&lt;/P&gt;&lt;P&gt;Thanks,&lt;BR /&gt;Yarden.&lt;/P&gt;</description>
    <pubDate>Mon, 07 Oct 2024 11:48:15 GMT</pubDate>
    <dc:creator>Yarden</dc:creator>
    <dc:date>2024-10-07T11:48:15Z</dc:date>
    <item>
      <title>Sync table A to table B, triggered by any change in table A.</title>
      <link>https://community.databricks.com/t5/data-engineering/sync-table-a-to-table-b-triggered-by-any-change-in-table-a/m-p/92946#M38589</link>
      <description>&lt;P&gt;Hey,&lt;/P&gt;&lt;P&gt;I'm trying to find a way to sync table A to table B whenever table A is written to.&amp;nbsp;just with a trigger on write.&lt;BR /&gt;I want to avoid using any continuous runs or schedules.&lt;BR /&gt;Trying to get this to work inside Databricks, without having to use any outside listeners/triggers.&lt;/P&gt;&lt;P&gt;I tried looking into using a workflow that's triggered by new files in a volume - but I couldn't create a volume that is on the same location of the table I want to monitor.&lt;/P&gt;&lt;P&gt;What is the way to achieve this?&lt;/P&gt;&lt;P&gt;Thanks,&lt;BR /&gt;Yarden.&lt;/P&gt;</description>
      <pubDate>Mon, 07 Oct 2024 11:48:15 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/sync-table-a-to-table-b-triggered-by-any-change-in-table-a/m-p/92946#M38589</guid>
      <dc:creator>Yarden</dc:creator>
      <dc:date>2024-10-07T11:48:15Z</dc:date>
    </item>
    <item>
      <title>Re: Sync table A to table B, triggered by any change in table A.</title>
      <link>https://community.databricks.com/t5/data-engineering/sync-table-a-to-table-b-triggered-by-any-change-in-table-a/m-p/93953#M38791</link>
      <description>&lt;P&gt;&lt;a href="https://community.databricks.com/t5/user/viewprofilepage/user-id/125045"&gt;@Yarden&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;For this use case, Databricks does not have built-in triggers directly tied to Delta table write operations, as seen in traditional databases. However, you can achieve this functionality using one of the following approaches:&lt;/P&gt;&lt;H3&gt;Approach 1: File Arrival Triggers (Databricks Workflows)&lt;/H3&gt;&lt;P&gt;You can configure a Databricks workflow to trigger based on file arrivals in a directory. If table A writes files to a specific location (e.g., S3 or ADLS), a workflow can be set up to trigger whenever new files are detected.&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Steps:&lt;/STRONG&gt;&lt;/P&gt;&lt;OL&gt;&lt;LI&gt;Configure the workflow to monitor the location where table A’s data is written.&lt;/LI&gt;&lt;LI&gt;Set the workflow to trigger the syncing logic that updates table B.&lt;/LI&gt;&lt;LI&gt;For more details, &lt;A href="https://learn.microsoft.com/en-us/azure/databricks/jobs/file-arrival-triggers" target="_self"&gt;review the relevant documentation&lt;/A&gt;&lt;/LI&gt;&lt;/OL&gt;&lt;H3&gt;Approach 2: Databricks Autoloader with Directory Listing&lt;/H3&gt;&lt;P&gt;Another option is to use Autoloader on the directory where table A's data is written. When new files are added to the directory, Autoloader can trigger a job to sync the data from table A to table B.&lt;/P&gt;</description>
      <pubDate>Mon, 14 Oct 2024 23:23:33 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/sync-table-a-to-table-b-triggered-by-any-change-in-table-a/m-p/93953#M38791</guid>
      <dc:creator>Panda</dc:creator>
      <dc:date>2024-10-14T23:23:33Z</dc:date>
    </item>
  </channel>
</rss>

