cancel
Showing results forย 
Search instead forย 
Did you mean:ย 
Data Engineering
Join discussions on data engineering best practices, architectures, and optimization strategies within the Databricks Community. Exchange insights and solutions with fellow data engineers.
cancel
Showing results forย 
Search instead forย 
Did you mean:ย 

Can you perform a Merge into a Delta table from a stream?

User16826992666
Valued Contributor
 
1 ACCEPTED SOLUTION

Accepted Solutions

sajith_appukutt
Honored Contributor II

You could MERGE into a delta table from a stream using foreachBatch. Here is a sample notebook

View solution in original post

3 REPLIES 3

sajith_appukutt
Honored Contributor II

You could MERGE into a delta table from a stream using foreachBatch. Here is a sample notebook

Greg
New Contributor III

I am doing this exact thing with foreachBatch from a stream. However the Delta table I am merging into consumes a huge amount of space in relation to how much data is there due to the versions. Every MERGE execution will create new version. So if your stream is going to get lots of data that will trigger the MERGE, this may surprise you.

Anonymous
Not applicable

@Greg Moyerโ€‹ - Thank you. ๐Ÿ™‚

Connect with Databricks Users in Your Area

Join a Regional User Group to connect with local Databricks users. Events will be happening in your city, and you wonโ€™t want to miss the chance to attend and share knowledge.

If there isnโ€™t a group near you, start one and help create a community that brings people together.

Request a New Group