This mini project demonstrates how to use SQL queries to interact with and analyze data from a sample database.
It covers the basics of data retrieval, filtering, aggregation, and table relationships — perfect for beginners learning SQL.
This project contains:
- A sample SQL database (such as employees,students, orsales)
- A collection of SQL queries for:
- Creating tables
- Inserting sample data
- Performing simple SELECT,UPDATE, andDELETEoperations
- Using WHERE,GROUP BY,ORDER BY, andJOINclauses
 
- Basic SQL syntax
- Data insertion and updates
- Filtering with WHERE
- Sorting with ORDER BY
- Aggregation using COUNT,AVG,SUM,MIN, andMAX
- Combining data using INNER JOINandLEFT JOIN
- Open your SQL editor (MySQL Workbench, SQLite, or any online SQL compiler)
- Copy and paste the queries from this project.
- Run each query step by step to see how SQL works in real-time.
-- Create a sample table
CREATE TABLE students (
  id INT PRIMARY KEY,
  name VARCHAR(50),
  age INT,
  grade VARCHAR(5)
);
-- Insert data
INSERT INTO students VALUES
(1, 'Alice', 20, 'A'),
(2, 'Bob', 22, 'B'),
(3, 'Charlie', 21, 'A');
-- Select all students
SELECT * FROM students;
-- Find students with grade A
SELECT name FROM students WHERE grade = 'A';