Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

rlanier-webdev/SQL

Folders and files

NameName
Last commit message
Last commit date

Latest commit

History

17 Commits

Repository files navigation

๐Ÿงฎ Basic SQL Queries

This repository contains a collection of basic SQL queries I've written to practice and reinforce my understanding of fundamental SQL concepts. It's a personal learning project, perfect for beginners or anyone who wants a quick refresher on core SQL skills.


๐Ÿ“ Projects Included

1. ๐Ÿ“˜ SchoolDB

A simulated academic database designed for mastering SQL queries across a variety of real-world school scenariosโ€”students, instructors, courses, grades, and scheduling.

  • Focus Areas:

    • Database design and table creation with foreign keys
    • Joins across multiple tables (Students, Enrollments, Courses, Instructors)
    • Aggregation and filtering by semester, year, and grade
    • Practical views like class rosters, teaching assignments, and academic stats
  • Highlight Queries:

    • Student-course-instructor relationships via joins
    • Enrollment stats by course, semester, and grade
    • Sorting and filtering by enrollment date, email domain, and credit load
    • Determine which instructors teach specific courses
    • Count of courses taught per instructor and students per course

๐Ÿ“„ View SchoolDB README


2. ๐Ÿ›’ EcommerceDB

A simulated eCommerce database focused on customers, orders, products, and order details. This project explores various business logic scenarios like customer activity, revenue calculations, and order trends.

  • Focus Areas:

    • Filtering, pattern matching, and sorting
    • Aggregations and grouping (SUM, AVG, COUNT)
    • Joins across multiple related tables
    • Revenue analysis, product performance, and customer behavior
    • Subqueries and integrity validation (e.g., mismatched totals)
  • Highlight Queries:

    • Calculate total and average revenue per customer
    • Identify top 3 spending customers
    • Find all products never ordered
    • Validate order totals by comparing aggregated order detail prices
    • Retrieve detailed product purchase reports per customer and order

๐Ÿ“„ View EcommerceDB README


3. ๐Ÿ€ WNBADraftDB

A deep-dive into WNBA draft data with a focus on player performance, draft trends, and team-level insights. This project enhances SQL proficiency through ranking functions, conditional logic, and aggregate analysis.

  • Focus Areas:

    • Filtering and conditional queries (e.g., player stats, draft years)
    • Aggregation, grouping, and ranking (RANK() OVER, GROUP BY)
    • Advanced joins and subqueries for year-over-year comparisons
    • CASE statements for custom labels like 'Veteran' vs. 'Rookie'
    • Win shares analysis and college/team breakdowns
  • Highlight Queries:

    • Top scorers by total points (games ร—ใฐใค points per game)
    • Players ranked by win shares per 40 minutes
    • Average points per college and draftees per team
    • Label players as veterans or rookies based on years played
    • Determine draft-year leaders by performance
  • Data Source:

๐Ÿ“„ View WNBADraftDB README


4. ๐ŸŽค GrammysDB

A comprehensive SQL analysis of Grammy Awards data from 1965 to 2024, focused on uncovering insights into artist performance, award categories, and nomination patterns. This project reinforces key SQL concepts using a real-world entertainment dataset.

Focus Areas:

  • Filtering and pattern matching (e.g., song titles with "Love")
  • Aggregation and grouping (wins vs. nominations per artist/category)
  • CTEs and subqueries for advanced summarization
  • Identifying duplicates, outliers, and unique records
  • Conditional logic using CASE statements

Highlight Queries:

  • Most nominated artist in a single year
  • Artists with Grammy wins in 3+ different categories
  • Duplicate nominations across years and categories
  • Songs with multiple producers or recurring title themes
  • Artists who were nominated but never won

Data Source:

๐Ÿ“„ View GrammysDB README


๐Ÿ”ง Tools Used

  • SQL Server (T-SQL)
  • Custom-built sample databases
  • SSMS (SQL Server Management Studio)

๐ŸŽ“ Purpose

  • Practice SQL querying techniques in real-world-style datasets.
  • Reinforce foundational and intermediate SQL concepts.
  • Build a portfolio of practical SQL solutions.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

AltStyle ใซใ‚ˆใฃใฆๅค‰ๆ›ใ•ใ‚ŒใŸใƒšใƒผใ‚ธ (->ใ‚ชใƒชใ‚ธใƒŠใƒซ) /