DZone
Thanks for visiting DZone today,
Edit Profile
  • Manage Email Subscriptions
  • How to Post to DZone
  • Article Submission Guidelines
Sign Out View Profile
  • Post an Article
  • Manage My Drafts
Over 2 million developers have joined DZone.
Log In / Join
Please enter at least three characters to search
Refcards Trend Reports
Events Video Library
Refcards
Trend Reports

Events

View Events Video Library

Zones

Culture and Methodologies Agile Career Development Methodologies Team Management
Data Engineering AI/ML Big Data Data Databases IoT
Software Design and Architecture Cloud Architecture Containers Integration Microservices Performance Security
Coding Frameworks Java JavaScript Languages Tools
Testing, Deployment, and Maintenance Deployment DevOps and CI/CD Maintenance Monitoring and Observability Testing, Tools, and Frameworks
Culture and Methodologies
Agile Career Development Methodologies Team Management
Data Engineering
AI/ML Big Data Data Databases IoT
Software Design and Architecture
Cloud Architecture Containers Integration Microservices Performance Security
Coding
Frameworks Java JavaScript Languages Tools
Testing, Deployment, and Maintenance
Deployment DevOps and CI/CD Maintenance Monitoring and Observability Testing, Tools, and Frameworks

Last call! Secure your stack and shape the future! Help dev teams across the globe navigate their software supply chain security challenges.

Modernize your data layer. Learn how to design cloud-native database architectures to meet the evolving demands of AI and GenAI workloads.

Releasing software shouldn't be stressful or risky. Learn how to leverage progressive delivery techniques to ensure safer deployments.

Avoid machine learning mistakes and boost model performance! Discover key ML patterns, anti-patterns, data strategies, and more.

Related

  • Designing a Blog Application Using Document Databases
  • Relational DB Migration to S3 Data Lake Via AWS DMS, Part I
  • NoSQL for Relational Minds
  • Business Logic Database Agent

Trending

  • Understanding and Mitigating IP Spoofing Attacks
  • MySQL to PostgreSQL Database Migration: A Practical Case Study
  • Java's Quiet Revolution: Thriving in the Serverless Kubernetes Era
  • How to Build Local LLM RAG Apps With Ollama, DeepSeek-R1, and SingleStore
  1. DZone
  2. Data Engineering
  3. Databases
  4. What Is Database Synchronization?

What Is Database Synchronization?

Here you can find information about various types of synchronization: Insert, Update, Drop, Mixed.

By 
Dmitry Narizhnykh user avatar
Dmitry Narizhnykh
DZone Core CORE ·
Updated Aug. 18, 20 · Tutorial
Likes (3)
Comment
Save
Tweet
Share
17.3K Views

Join the DZone community and get the full member experience.

Join For Free


Database synchronization establishes data consistency between two or more databases, automatically copying changes back and forth. Harmonization of the data over time should be performed continuously. Pulling out data from source (master) database to destination (slave) is the most trivial case.

NOTE: Synchronization works on the base of Primary Key constraint. The structures of Databases should contain Primary Key or a Unique or Primary index, not a composite one.

Below you can find information about various types of synchronization:

  • Insert Synchronization
  • Update Synchronization
  • Drop Synchronization
  • Mixed Synchronization

Insert Database Synchronization

New records from the Source table will be automatically transferred to the target, in case there are no appropriate records in the destination table with identical Primary Key values. As a result of the Database Sync process, absent records will be inserted into destination tables.

The following scheme illustrates the "Insert synchronization process".

 

Update Database Synchronization

When changes in the source database occur, appropriate changes in target DB have to be performed. Synchronizer compares records' values at first. Then altered records will be replaced at destination tables to establish the identity between two tables. As a result of update synchronization, all your data keep updated.

Given below picture illustrates update sync process.

 

Drop Database Synchronization

If some records have been deleted from a source, corresponding records have to be deleted from the destination. With the checked "Drop-sync option," these old records will be removed from the target if they do not exist in the source.

The Drop sync process is shown schematically below.

 

Mixed Database Synchronization

For example, you've made modifications in your source tables, added completely new records, and removed obsolete rows. To keep your databases in relevance, you have to add, delete, and update these correspondent records in the destination database.

The picture below shows how Insert, Update and Drop sync options work together.


Check out cross-database conversion and synchronization software that migrates data between the most popular on-premises databases, including SQL Server, MySQL, Oracle, PostgreSQL. 

Cloud Platforms like AWS RDS/ Aurora, Microsoft Azure SQL, Google Cloud SQL are supported.

Database Relational database

Published at DZone with permission of Dmitry Narizhnykh. See the original article here.

Opinions expressed by DZone contributors are their own.

Related

  • Designing a Blog Application Using Document Databases
  • Relational DB Migration to S3 Data Lake Via AWS DMS, Part I
  • NoSQL for Relational Minds
  • Business Logic Database Agent

Partner Resources

×

Comments
Oops! Something Went Wrong

The likes didn't load as expected. Please refresh the page and try again.

ABOUT US

  • About DZone
  • Support and feedback
  • Community research
  • Sitemap

ADVERTISE

  • Advertise with DZone

CONTRIBUTE ON DZONE

  • Article Submission Guidelines
  • Become a Contributor
  • Core Program
  • Visit the Writers' Zone

LEGAL

  • Terms of Service
  • Privacy Policy

CONTACT US

  • 3343 Perimeter Hill Drive
  • Suite 100
  • Nashville, TN 37211
  • support@dzone.com

Let's be friends:

Likes
There are no likes...yet! 👀
Be the first to like this post!
It looks like you're not logged in.
Sign in to see who liked this post!