<?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 How to Capture Change Data (CDC) from DynamoDB Streams and Write into Delta table of DataBricks in Data Engineering</title>
    <link>https://community.databricks.com/t5/data-engineering/how-to-capture-change-data-cdc-from-dynamodb-streams-and-write/m-p/59962#M31550</link>
    <description>&lt;P&gt;Can anyone give me Steps to achieve this.&lt;/P&gt;</description>
    <pubDate>Mon, 12 Feb 2024 17:21:04 GMT</pubDate>
    <dc:creator>prasad95</dc:creator>
    <dc:date>2024-02-12T17:21:04Z</dc:date>
    <item>
      <title>How to Capture Change Data (CDC) from DynamoDB Streams and Write into Delta table of DataBricks</title>
      <link>https://community.databricks.com/t5/data-engineering/how-to-capture-change-data-cdc-from-dynamodb-streams-and-write/m-p/59962#M31550</link>
      <description>&lt;P&gt;Can anyone give me Steps to achieve this.&lt;/P&gt;</description>
      <pubDate>Mon, 12 Feb 2024 17:21:04 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/how-to-capture-change-data-cdc-from-dynamodb-streams-and-write/m-p/59962#M31550</guid>
      <dc:creator>prasad95</dc:creator>
      <dc:date>2024-02-12T17:21:04Z</dc:date>
    </item>
    <item>
      <title>Re: How to Capture Change Data (CDC) from DynamoDB Streams and Write into Delta table of DataBricks</title>
      <link>https://community.databricks.com/t5/data-engineering/how-to-capture-change-data-cdc-from-dynamodb-streams-and-write/m-p/60040#M31572</link>
      <description>&lt;P&gt;Hi,&amp;nbsp;&lt;a href="https://community.databricks.com/t5/user/viewprofilepage/user-id/97977"&gt;@prasad95&lt;/a&gt;&amp;nbsp;Thank you for sharing your concern here.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;In addition to the&amp;nbsp;&lt;a href="https://community.databricks.com/t5/user/viewprofilepage/user-id/9"&gt;@Retired_mod&lt;/a&gt;&amp;nbsp;comments you can follow below&amp;nbsp;&lt;SPAN&gt;To capture Change Data (CDC) from DynamoDB Streams and write it into a Delta table in Databricks:&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;1. Connect to DynamoDB Streams and read the CDC data using the AWS SDK.&lt;BR /&gt;2. Process the CDC data in Databricks using the&amp;nbsp;&lt;CODE class="c-mrkdwn__code" data-stringify-type="code"&gt;APPLY CHANGES&lt;/CODE&gt;&amp;nbsp;API in Delta Live Tables, which is designed to correctly process CDC records.&lt;BR /&gt;3. Use the&amp;nbsp;&lt;CODE class="c-mrkdwn__code" data-stringify-type="code"&gt;APPLY CHANGES INTO&lt;/CODE&gt;&amp;nbsp;statement with the&amp;nbsp;&lt;CODE class="c-mrkdwn__code" data-stringify-type="code"&gt;APPLY CHANGES&lt;/CODE&gt;&amp;nbsp;API. An example of its usage is:&lt;/SPAN&gt;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;CREATE OR REFRESH STREAMING TABLE table_name;
APPLY CHANGES INTO LIVE.table_name FROM source KEYS (keys)
[IGNORE NULL UPDATES]
[APPLY AS DELETE WHEN condition]
[APPLY AS TRUNCATE WHEN condition]
SEQUENCE BY orderByColumn
[COLUMNS {columnList | * EXCEPT (exceptColumnList)}]
[STORED AS {SCD TYPE 1 | SCD TYPE 2}]
[TRACK HISTORY ON {columnList | * EXCEPT (exceptColumnList)}]&lt;/LI-CODE&gt;
&lt;P&gt;&lt;SPAN&gt;In this statement,&amp;nbsp;&lt;/SPAN&gt;&lt;CODE class="c-mrkdwn__code" data-stringify-type="code"&gt;source&lt;/CODE&gt;&lt;SPAN&gt;&amp;nbsp;is the CDC data from DynamoDB Streams, and&amp;nbsp;&lt;/SPAN&gt;&lt;CODE class="c-mrkdwn__code" data-stringify-type="code"&gt;table_name&lt;/CODE&gt;&lt;SPAN&gt;&amp;nbsp;is the Delta table where you want to write the CDC data.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;4. After executing this statement, the CDC data from DynamoDB Streams is written into the Delta table in Databricks.&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;Remember to define unique keys for each row in the source data. If you want to track history on certain columns, use the&amp;nbsp;&lt;/SPAN&gt;&lt;CODE class="c-mrkdwn__code" data-stringify-type="code"&gt;TRACK HISTORY ON&lt;/CODE&gt;&lt;SPAN&gt;&amp;nbsp;clause.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;You can go through the below links to understand more about this.&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&lt;A href="https://docs.databricks.com/en/delta-live-tables/cdc.html#how-is-cdc-implemented-with-delta-live-tables" target="_blank"&gt;https://docs.databricks.com/en/delta-live-tables/cdc.html#how-is-cdc-implemented-with-delta-live-tables&lt;/A&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;DLT with SQL reference:- &lt;A href="https://docs.databricks.com/en/delta-live-tables/sql-ref.html" target="_blank"&gt;https://docs.databricks.com/en/delta-live-tables/sql-ref.html&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;Please leave a like if it is helpful. Follow-ups are appreciated.&lt;/P&gt;
&lt;P&gt;Kudos,&lt;/P&gt;
&lt;P&gt;Sai Kumar&lt;/P&gt;</description>
      <pubDate>Tue, 13 Feb 2024 12:19:35 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/how-to-capture-change-data-cdc-from-dynamodb-streams-and-write/m-p/60040#M31572</guid>
      <dc:creator>saikumar246</dc:creator>
      <dc:date>2024-02-13T12:19:35Z</dc:date>
    </item>
    <item>
      <title>Re: How to Capture Change Data (CDC) from DynamoDB Streams and Write into Delta table of DataBricks</title>
      <link>https://community.databricks.com/t5/data-engineering/how-to-capture-change-data-cdc-from-dynamodb-streams-and-write/m-p/60300#M31627</link>
      <description>&lt;P&gt;&lt;a href="https://community.databricks.com/t5/user/viewprofilepage/user-id/9"&gt;@Retired_mod&lt;/a&gt;&amp;nbsp;Thanks for detail overview.&lt;BR /&gt;But can you tell more about - How should i fetch DynamoDB Streams generated data (which will reside in S3) to Delta Table via Notebook (automated by Job).&lt;BR /&gt;I saw in official docs that if i use Job(Notebook) Trigger as &lt;EM&gt;&lt;STRONG&gt;file arrival&lt;/STRONG&gt;&lt;/EM&gt; but there is limit of Max 50 [&lt;A href="https://docs.databricks.com/en/workflows/jobs/file-arrival-triggers.html#limitations" target="_self"&gt;Reference Docs&lt;/A&gt;].&lt;/P&gt;&lt;P&gt;If i have to implement for more than 50 table how can i manage this.&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 15 Feb 2024 10:00:10 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/how-to-capture-change-data-cdc-from-dynamodb-streams-and-write/m-p/60300#M31627</guid>
      <dc:creator>prasad95</dc:creator>
      <dc:date>2024-02-15T10:00:10Z</dc:date>
    </item>
    <item>
      <title>Re: How to Capture Change Data (CDC) from DynamoDB Streams and Write into Delta table of DataBricks</title>
      <link>https://community.databricks.com/t5/data-engineering/how-to-capture-change-data-cdc-from-dynamodb-streams-and-write/m-p/60301#M31628</link>
      <description>&lt;P&gt;&lt;a href="https://community.databricks.com/t5/user/viewprofilepage/user-id/40400"&gt;@saikumar246&lt;/a&gt;&amp;nbsp;Thanks for Detailed steps &amp;amp; Explanation.&lt;BR /&gt;Can you help with this - &lt;A href="https://community.databricks.com/t5/data-engineering/how-to-capture-change-data-cdc-from-dynamodb-streams-and-write/m-p/60016/highlight/true#M31565" target="_self"&gt;comment&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 15 Feb 2024 10:04:49 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/how-to-capture-change-data-cdc-from-dynamodb-streams-and-write/m-p/60301#M31628</guid>
      <dc:creator>prasad95</dc:creator>
      <dc:date>2024-02-15T10:04:49Z</dc:date>
    </item>
  </channel>
</rss>

