# rishabhsm2004/sql-project architecture

> Architecture diagram of the GitHub repository rishabhsm2004/sql-project, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-01). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/rishabhsm2004/sql-project
- Repository: https://github.com/rishabhsm2004/sql-project

## Overview

This small SQL analysis project turns a layoffs dataset into cleaned staging data, then uses exploratory queries to surface company, location, industry, and time-based trends. The README documents the cleaning and analysis stages and MySQL as the database technology; source excerpts were not provided, so relationships are limited to those documented there.

Main entry points: [`world_layoffs - EDA.sql`](https://github.com/rishabhsm2004/sql-project/blob/main/world_layoffs%20-%20EDA.sql) (Layoffs analysis), [`world_Layoffs- Data Cleaning.sql`](https://github.com/rishabhsm2004/sql-project/blob/main/world_Layoffs-%20Data%20Cleaning.sql) (Data cleaning), [`layoffs.csv`](https://github.com/rishabhsm2004/sql-project/blob/main/layoffs.csv) (Raw layoffs data)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_prep["Data preparation"]
  node_raw["Raw layoffs data<br/>[layoffs.csv]"]
  node_cleaning["Data cleaning"]
  node_staging[("Cleaned staging data")]
end

subgraph group_analysis["Exploratory analysis"]
  node_eda["Layoffs analysis"]
  node_insights["Trend insights"]
end

node_analyst(("Analyst"))

node_raw -->|"cleans"| node_cleaning
node_cleaning -->|"creates"| node_staging
node_staging -->|"analyzes"| node_eda
node_analyst -->|"explores"| node_eda
node_eda -->|"identifies"| node_insights

click node_raw "https://github.com/rishabhsm2004/sql-project/blob/main/layoffs.csv"
click node_cleaning "https://github.com/rishabhsm2004/sql-project/blob/main/world_Layoffs-%20Data%20Cleaning.sql"
click node_staging "https://github.com/rishabhsm2004/sql-project/blob/main/world_Layoffs-%20Data%20Cleaning.sql"
click node_eda "https://github.com/rishabhsm2004/sql-project/blob/main/world_layoffs%20-%20EDA.sql"
click node_insights "https://github.com/rishabhsm2004/sql-project/blob/main/world_layoffs%20-%20EDA.sql"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_raw,node_cleaning,node_staging toneBlue
class node_eda,node_insights toneAmber
class node_analyst toneIndigo
```

## Components

### Data preparation

- [Raw layoffs data](https://github.com/rishabhsm2004/sql-project/blob/main/layoffs.csv): `layoffs.csv`
- [Data cleaning](https://github.com/rishabhsm2004/sql-project/blob/main/world_Layoffs-%20Data%20Cleaning.sql): `world_Layoffs- Data Cleaning.sql`
- [Cleaned staging data](https://github.com/rishabhsm2004/sql-project/blob/main/world_Layoffs-%20Data%20Cleaning.sql): `world_Layoffs- Data Cleaning.sql`

### Exploratory analysis

- [Layoffs analysis](https://github.com/rishabhsm2004/sql-project/blob/main/world_layoffs%20-%20EDA.sql): `world_layoffs - EDA.sql`
- [Trend insights](https://github.com/rishabhsm2004/sql-project/blob/main/world_layoffs%20-%20EDA.sql): `world_layoffs - EDA.sql`

### Other components

- **Analyst**

## Connections

- Raw layoffs data → Data cleaning: cleans (evidence: `README.md`)
- Data cleaning → Cleaned staging data: creates (evidence: `README.md`)
- Cleaned staging data → Layoffs analysis: analyzes (evidence: `README.md`)
- Analyst → Layoffs analysis: explores (evidence: `README.md`)
- Layoffs analysis → Trend insights: identifies (evidence: `README.md`)
