🧮✨ A curated collection of SQL programming exercises and solutions. This repository follows a database systems curriculum and explores SQL queries, relational algebra, PL/SQL programming, Datalog, and data modeling concepts through hands-on practice.
- Connecting to Oracle Databases: Secure SSH tunneling and client configuration.
- Query Syntax:
SELECT,WHERE,FROM,DISTINCT,ORDER BY, and aliases. - Filtering and Conditions:
AND,OR,NOT, comparison operators, and pattern matching.
- Set Operators in SQL:
UNION,INTERSECT,MINUS - Relational Algebra Expressions: Mapping algebra to SQL and vice versa.
- Multisets vs Sets: Handling duplicates and understanding bag semantics.
- Aggregate Functions:
MIN,MAX,SUM,AVG,COUNT - GROUP BY and HAVING: Group filtering and aggregation logic.
- Derived Columns: Categorizing and formatting results using functions.
- Join Types: Inner, outer, and natural joins.
- Join Syntax: Explicit (
JOIN ON) and implicit (WHERE) syntax. - Subqueries: Correlated and non-correlated subqueries in filters and projections.
- DML Statements:
INSERT,UPDATE,DELETE - DDL Statements:
CREATE,ALTER,DROP,TRUNCATE - Views and Constraints: Virtual tables, indexes, primary and foreign keys.
- PL/SQL Basics: Anonymous blocks and syntax structure.
- Procedures and Functions: Creating reusable logic with parameters and return types.
- Control Flow:
IF,CASE,LOOP,WHILE, and conditional branching. - Cursors: Explicit and implicit cursors for row-by-row processing.
- Exception Handling: Catching and managing runtime errors using
EXCEPTIONblocks. - PL/SQL Tables and Collections: Working with indexed tables, records, and arrays.
- Rule-Based Queries: Declarative definitions of relations.
- Recursive Logic: Defining transitive closures and hierarchical queries.
- Datalog in SQL: Emulating recursion using Oracle’s
CONNECT BYand CTEs.