Skip to content

Commit 7239773

Browse files
committed
feat(sql-dml): add overview of DML (Data Manipulation Language) commands
What - Documented key DML commands in SQL that allow manipulation of data within tables: - INSERT → add new records into a table. - UPDATE → modify existing records. - DELETE → remove records. - MERGE (in some DBs) → combine insert, update, and delete logic. - Explained syntax and purpose of each command with examples. - Clarified difference between DML and DDL (DML changes data, not structure). Why - DML is the core of interacting with relational databases — almost every application uses these commands. - Understanding DML is crucial for building CRUD operations in Java + JDBC. - Ensures learners know how to manipulate existing data as opposed to just creating schema. How to use - INSERT: Add a new employee into `employees` table. - UPDATE: Change salary for employees in a given department. - DELETE: Remove inactive customers. - MERGE: Synchronize staging tables with production tables. Real-life Applications - Banking: Update balances after transactions. - E-commerce: Insert new orders and delete expired carts. - HR systems: Update employee details (promotions, transfers). - Analytics: Merge incremental data loads into main warehouse tables. Notes - Always use WHERE clause in UPDATE and DELETE to avoid unintentional full-table changes. - Transactions (COMMIT/ROLLBACK) should wrap DML in critical systems to ensure data integrity. Signed-off-by: https://github.com/Someshdiwan <[email protected]>
1 parent cd19f05 commit 7239773

File tree

3 files changed

+0
-0
lines changed