Skip to content

Bayt-al-Hikmah/SQL

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

SQL Introduction Course

Welcome to the SQL Introduction Course repository by Bayt-al-Hikmah! This collection of lecture notes is designed for beginners and intermediate learners aiming to master SQL fundamentals using SQLite. Whether you're new to databases or refreshing your skills, these notes provide structured, step-by-step guidance through core concepts.

Bayt-al-Hikmah (House of Wisdom) is dedicated to preserving and disseminating knowledge, inspired by the historic intellectual center of the Islamic Golden Age. These lectures emphasize clear explanations, practical examples, and hands-on exercises to build a strong foundation in SQL.

Prerequisites

  • Basic familiarity with computers and file management.

  • No prior database or programming experience required (though helpful).

  • SQLite installed or access to an online SQLite environment (e.g., DB Browser for SQLite, SQLiteOnline).

Setup Instructions

  1. Install SQLite:

    • Windows/Linux/macOS: Download from sqlite.org.

    • Alternatively, use an online tool like SQLiteOnline.

  2. Install a database management tool: DB Browser for SQLite or Visual Studio Code with the SQLite extension is recommended for beginners.

  3. Test your setup: Create a simple database and run a basic SELECT query (example in Chapter 1).

Course Overview

This 5-lecture series covers essential SQL topics progressively. Each lecture includes:

  • Theoretical explanations.

  • Code examples and snippets.

  • Exercises for practice.

  • References for further reading.

Chapter Topic Key Concepts Covered
Chapter 1 Introduction to SQLite Commands and ERD Design Basic SQLite commands, database creation, Entity-Relationship Diagram (ERD) design.
Chapter 2 Creating Tables, Working with Constraints, and Establishing Relationships Table creation, primary/foreign keys, constraints (NOT NULL, UNIQUE, etc.), relationships.
Chapter 3 Selecting, Inserting, Deleting, and Updating Data SELECT, INSERT, DELETE, UPDATE statements, filtering with WHERE.
Chapter 4 Advanced Querying with Joins, Subqueries, Aggregation Functions, and Transactions INNER/OUTER JOINs, subqueries, COUNT/SUM/AVG, transaction management.
Chapter 5 Views, Indexes, and Triggers Creating views, optimizing with indexes, automating with triggers.

Recommended Pace: 1-2 chapters per week, with time for practice. Total estimated time: 15-25 hours.

Practice and Projects

  • Exercises: Each chapter ends with SQL challenges. Solutions can be added in a separate /exercises folder.

  • Mini-Project Ideas:

    • Chapter 2: Design a database for a small library system with tables and relationships.

    • Chapter 3: Build a simple inventory management system with CRUD operations.

    • Chapter 5: Create a view and trigger for a customer order tracking system.

  • Resources: sqlite.org for documentation, SQLZoo for interactive problems, and W3Schools SQL for tutorials.

Contributing

We welcome contributions! Help expand these notes with:

  • Corrections or clarifications.

  • Additional examples or exercises.

  • Translations or adaptations.

License

This project is licensed under the MIT License feel free to use, modify, and distribute.

Contact

Questions? Open an issue or reach out via:

Happy querying! 🚀 Let's build wisdom through databases.

About

Introduction course to SQL and SQLite

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors