项目 / DataWithBaraa/sql-data-warehouse-project
Build a data warehouse in SQL Server from two source systems, a CRM and an ERP, through bronze, silver and gold. The files and scripts of the free full project.
本站整理,非 GitHub 官方 description。
官方快照(gh_history.db,2026-11-25):总榜 未进 Top50 · 日榜 未进 Top50 · 周榜未满 7 天基线(官方不生成) · 月榜暂无官方口径;下方四卡为站内趋势聚合(周卡按上榜次数,非官方 7 日增量窗)。
以下三段按该项目自己的 GitHub README 章节摘录(可合理截断并标明);README 没有对应章节的留空,不编造。
新同学先打开[仓库](https://github.com/DataWithBaraa/sql-data-warehouse-project)中的 `00_setup` 安装指南,按说明安装 SQL Server 并建库,再依 `03_scripts` 的顺序运行脚本。视频各章与对应文件也在[仓库 README](https://github.com/DataWithBaraa/sql-data-warehouse-project)中列出。
项目采用 Bronze、Silver、Gold 三层数据仓库架构,从 CSV 导入 SQL Server,经清洗标准化后建模为星型模型供报表分析。
来自 GitHub 仓库 README / 主页介绍正文,原样摘录,共 15,926 字节。
# Data Warehouse and Analytics Project [](https://www.youtube.com/@datawithbaraa) [](https://www.udemy.com/course/building-a-modern-data-warehouse-data-engineering-bootcamp/) [](https://www.datawithbaraa.com) [](LICENSE) [](https://github.com/DataWithBaraa/sql-data-warehouse-project) The materials of the data warehouse project: the source files, every script from the videos, and the docs. ⭐ If this project helps you, star the repository so other learners can find it too. You take raw files from two systems, a CRM and an ERP, and build one data warehouse in SQL Server. At the end, the data is clean and ready for analysis. **New here? Open the setup guide in the `00_setup` folder.** It walks you through installing SQL Server and creating the database, on Windows and Mac, with the fixes for the common errors. ``` sql-data-warehouse-project/ ├── 00_setup/ the setup guide, and the one-click Docker start for Mac ├── 01_datasets/ the six source files the project loads │ ├── source_crm/ three files from the CRM system │ └── source_erp/ three files from the ERP system ├── 02_docs/ the requirements, the diagrams and the notes ├── 03_scripts/ the project scripts, in the order of the videos │ ├── init_database.sql creates the database: run it first │ ├── bronze/ loads the raw files │ ├── silver/ cleans and prepares the data │ └── gold/ builds the tables for analysis └── 04_tests/ checks the quality of the silver and gold data ``` The project reads the six files from `C:\sql\dwh_project\01_datasets\`. Put the folder there, or change the six paths in `03_scripts/bronze/proc_load_bronze.sql`. The videos show the folders without numbers: `datasets` there is `01_datasets` here, `scripts` is `03_scripts`. <details> <summary><b>The 45 chapters</b>: the minute in the video and the files of each one</summary> | # | Chapter | Video | Files | |--:|:--|:--|:--| | 1 | Intro | [0:00:00](https://youtu.be/9GVqKuTVANE?t=0) | | | 2 | Types of SQL Projects | [0:01:27](https://youtu.be/9GVqKuTVANE?t=87) | | | 3 | What is Data Warehouse | [0:02:50](https://youtu.be/9GVqKuTVANE?t=170) | | | 4 | What is ETL | [0:09:41](https://youtu.be/9GVqKuTVANE?t=581) | [ETL.png](02_docs/ETL.png) | | 5 | Project Materials | [0:20:29](https://youtu.be/9GVqKuTVANE?t=1229) | [the setup guide](00_setup) | | 6 | Project Plan Using Notion | [0:23:14](https://youtu.be/9GVqKuTVANE?t=1394) | [Notion template](https://www.notion.com/templates/sql-data-warehouse-project) | | 7 | Analyzing Requirements | [0:30:54](https://youtu.be/9GVqKuTVANE?t=1854) | [requirements.md](02_docs/requirements.md) · [Project_Requirements.pdf](02_docs/Project_Requirements.pdf) | | 8 | Design The Data Architecture | [0:34:10](https://youtu.be/9GVqKuTVANE?t=2050) | [data_architecture.png](02_docs/data_architecture.png) | | 9 | Choose the Right Approach | [0:35:20](https://youtu.be/9GVqKuTVANE?t=2120) | | | 10 | Design the Layers of DWH | [0:40:43](https://youtu.be/9GVqKuTVANE?t=2443) | [data_layers.pdf](02_docs/data_layers.pdf) | | 11 | Draw the Architecture using Draw.io | [0:47:37](https://youtu.be/9GVqKuTVANE?t=2857) | [data_architecture.png](02_docs/data_architecture.png) | | 12 | Project Initialization | [0:56:00](https://youtu.be/9GVqKuTVANE?t=3360) | | | 13 | Define Naming Conventions | [0:56:56](https://youtu.be/9GVqKuTVANE?t=3416) | [naming_conventions.md](02_docs/naming_conventions.md) | | 14 | Prepare Your GIT Repository | [1:03:26](https://youtu.be/9GVqKuTVANE?t=3806) | | | 15 | Create Database & Schemas | [1:07:54](https://youtu.be/9GVqKuTVANE?t=4074) | [init_database.sql](03_scripts/init_database.sql) | | 16 | Commit Code in Git Repo | [1:10:33](https://youtu.be/9GVqKuTVANE?t=4233) | | | 17 | Build Bronze Layer | [1:13:14](https://youtu.be/9GVqKuTVANE?t=4394) | | | 18 | Analyze Source Systems | [1:14:36](https://youtu.be/9GVqKuTVANE?t=4476) | [01_datasets](01_datasets) | | 19 | Create DDL for Bronze Tables | [1:18:40](https://youtu.be/9GVqKuTVANE?t=4720) | [ddl_bronze.sql](03_scripts/bronze/ddl_bronze.sql) | | 20 | Develop SQL Load Scripts | [1:24:21](https://youtu.be/9GVqKuTVANE?t=5061) | [proc_load_bronze.sql](03_scripts/bronze/proc_load_bronze.sql) | | 21 | Create Bronze Stored Procedure | [1:32:18](https://youtu.be/9GVqKuTVANE?t=5538) | [proc_load_bronze.sql](03_scripts/bronze/proc_load_bronze.sql) | | 22 | Document: Bronze Data Flow | [1:45:28](https://youtu.be/9GVqKuTVANE?t=6328) | [data_flow.png](02_docs/data_flow.png) | | 23 | Build Silver Layer | [1:50:31](https://youtu.be/9GVqKuTVANE?t=6631) | | | 24 | Explore & Understand The Data | [1:52:08](https://youtu.be/9GVqKuTVANE?t=6728) | [data_integration.png](02_docs/data_integration.png) | | 25 | Create DDL for Silver Tables | [2:03:05](https://youtu.be/9GVqKuTVANE?t=7385) | [ddl_silver.sql](03_scripts/silver/ddl_silver.sql) | | 26 | Clean & Load crm_cust_info | [2:06:52](https://youtu.be/9GVqKuTVANE?t=7612) | [proc_load_silver.sql](03_scripts/silver/proc_load_silver.sql) | | 27 | Clean & Load crm_prd_info | [2:22:03](https://youtu.be/9GVqKuTVANE?t=8523) | [proc_load_silver.sql](03_scripts/silver/proc_load_silver.sql) | | 28 | Clean & Load crm_sales_details | [2:42:48](https://youtu.be/9GVqKuTVANE?t=9768) | [proc_load_silver.sql](03_scripts/silver/proc_load_silver.sql) | | 29 | Clean & Load erp_cust_az12 | [2:59:38](https://youtu.be/9GVqKuTVANE?t=10778) | [proc_load_silver.sql](03_scripts/silver/proc_load_silver.sql) | | 30 | Clean & Load erp_loc_a101 | [3:08:38](https://youtu.be/9GVqKuTVANE?t=11318) | [proc_load_silver.sql](03_scripts/silver/proc_load_silver.sql) | | 31 | Clean & Load erp_px_cat_g1v2 | [3:14:16](https://youtu.be/9GVqKuTVANE?t=11656) | [proc_load_silver.sql](03_scripts/silver/proc_load_silver.sql) | | 32 | Create Silver Stored Procedure | [3:18:38](https://youtu.be/9GVqKuTVANE?t=11918) | [proc_load_silver.sql](03_scripts/silver/proc_load_silver.sql) | | 33 | Document: Silver Data Flow | [3:24:29](https://youtu.be/9GVqKuTVANE?t=12269) | [data_flow.png](02_docs/data_flow.png) | | 34 | Build Gold Layer | [3:28:09](https://youtu.be/9GVqKuTVANE?t=12489) | | | 35 | What is Data Modeling? | [3:29:39](https://youtu.be/9GVqKuTVANE?t=12579) | | | 36 | Star Schema vs. Snowflake Schema | [3:32:17](https://youtu.be/9GVqKuTVANE?t=12737) | | | 37 | Dimensions vs Facts | [3:34:06](https://youtu.be/9GVqKuTVANE?t=12846) | | | 38 | Explore the Business Objects | [3:35:10](https://youtu.be/9GVqKuTVANE?t=12910) | | | 39 | Create Dimension Customers | [3:39:04](https://youtu.be/9GVqKuTVANE?t=13144) | [ddl_gold.sql](03_scripts/gold/ddl_gold.sql) | | 40 | Create Dimension Products | [3:55:30](https://youtu.be/9GVqKuTVANE?t=14130) | [ddl_gold.sql](03_scripts/gold/ddl_gold.sql) | | 41 | Create Fact Sales | [4:02:43](https://youtu.be/9GVqKuTVANE?t=14563) | [ddl_gold.sql](03_scripts/gold/ddl_gold.sql) | | 42 | Build The Star Schema Model | [4:08:48](https://youtu.be/9GVqKuTVANE?t=14928) | [data_model.png](02_docs/data_model.png) | | 43 | Data Catalog | [4:13:58](https://youtu.be/9GVqKuTVANE?t=15238) | [data_catalog.md](02_docs/data_catalog.md) | | 44 | Data Flow | [4:16:40](https://youtu.be/9GVqKuTVANE?t=15400) | [data_flow.png](02_docs/data_flow.png) | | 45 | End of Project | [4:21:45](https://youtu.be/9GVqKuTVANE?t=15705) | | The sketches of the whole project: [Project_Notes_Sketches.pdf](02_docs/Project_Notes_Sketches.pdf). The quality checks: [quality_checks_silver.sql](04_tests/quality_checks_silver.sql) and [quality_checks_gold.sql](04_tests/quality_checks_gold.sql). </details> --- ## 🏗️ Data Architecture The data architecture for this project follows Medallion Architecture **Bronze**, **Silver**, and **Gold** layers:  1. **Bronze Layer**: Stores raw data as-is from the source systems. Data is ingested from CSV Files into SQL Server Database. 2. **Silver Layer**: This layer includes data cleansing, standardization, and normalization processes to prepare data for analysis. 3. **Gold Layer**: Houses business-ready data modeled into a star schema required for reporting and analytics. --- ## 📖 Project Overview In this project, you: 1. **Design the architecture:** a modern data warehouse with three layers, bronze, silver and gold. 2. **Build the ETL pipelines:** load the source files and move the data through the layers. 3. **Model the data:** facts and dimensions, ready for reports. 4. **Analyze it:** answer business questions with SQL. --- ## 🛠️ Important Links & Tools - **SQL Server and SSMS:** the setup guide in `00_setup` has the links and every step. - **[Git](https://github.com/):** a GitHub account, to save and share your project. - **[draw.io](https://www.drawio.com/):** to draw the architecture and the data model. - **[Notion template](https://www.notion.com/templates/sql-data-warehouse-project):** the project plan, ready to copy. - **[Notion project steps](https://thankful-pangolin-2ca.notion.site/SQL-Data-Warehouse-Project-16ed041640ef80489667cfe2f380b269?pvs=4):** every phase and task of the project. --- ## 🚀 Project Requirements ### Building the Data Warehouse (Data Engineering) #### Objective Develop a modern data warehouse using SQL Server to consolidate sales data, enabling analytical reporting and informed decision-making. #### Specifications - **Data Sources**: Import data from two source systems (ERP and CRM) provided as CSV files. - **Data Quality**: Cleanse and resolve data quality issues prior to analysis. - **Integration**: Combine both sources into a single, user-friendly data model designed for analytical queries. - **Scope**: Focus on the latest dataset only; historization of data is not required. - **Documentation**: Provide clear documentation of the data model to support both business stakeholders and analytics teams. --- ### BI: Analytics & Reporting (Data Analysis) #### Objective Develop SQL-based analytics to deliver detailed insights into: - **Customer Behavior** - **Product Performance** - **Sales Trends** These insights empower stakeholders with key business metrics, enabling strategic decision-making. For more details, refer to [02_docs/requirements.md](02_docs/requirements.md). --- ## 🏆 Share your build Finished the project? Add this badge to the top of your own README, so others can find the original project too. [](https://github.com/DataWithBaraa/sql-data-warehouse-project) ```text [](https://github.com/DataWithBaraa/sql-data-warehouse-project) ``` Then show your build to the others in [Discussions, Show and tell](https://github.com/DataWithBaraa/sql-data-warehouse-project/discussions/categories/show-and-tell). --- ## 🎓 Learn with me Watch on YouTube, or take the guided version with a certificate on my Academy or Udemy. | Course | YouTube | My Academy | Udemy | |:--|:--|:--|:--| | **SQL** | [Full course](https://youtu.be/SSKVgrwhzus) · [Playlist](https://www.youtube.com/playlist?list=PLNcg_FV9n7qZY_2eAtUzEUulNjTJREhQe) | [Full Package](https://www.datawithbaraa.com/course/sql-full-course-for-beginners) · [Handbook](https://academy.datawithbaraa.com/l/digital_download/1087406/the-sql-handbook) | [SQL Bootcamp](https://www.udemy.com/course/the-complete-sql-bootcamp-30-hours-go-from-zero-to-hero/?referralCode=D20781228C2EB8B98339) · [SQL for Analytics](https://www.udemy.com/course/sql-mastery-for-data-analytics-and-business-intelligence/) | | **Python** | [Full course](https://youtu.be/Rq5gJVxz55Q) · [Playlist](https://www.youtube.com/playlist?list=PLNcg_FV9n7qZGfFl2ANI_zISzNp257Lwn) | [Full Package](https://www.datawithbaraa.com/course/the-ultimate-python-mastery) · [Handbook](https://academy.datawithbaraa.com/l/digital_download/998313/the-python-handbook) | [Python Bootcamp](https://www.udemy.com/course/the-complete-python-bootcamp-13hours-go-from-zero-to-hero/?referralCode=776491A4119FF8AF41CA) | | **Tableau** | [Full course](https://youtu.be/K3pXnbniUcM) · [Playlist](https://www.youtube.com/playlist?list=PLNcg_FV9n7qZJqrKcUUCWCWPYCrlcVm9v) | [Full Package](https://www.datawithbaraa.com/course/tableau-ultimate-full-course-for-beginners) | [Tableau Course](https://www.udemy.com/course/the-tableau-ultimate-course-from-zero-to-hero/?referralCode=6544726FDC491A6B25EC) · [Chart Masterclass](https://www.udemy.com/course/the-tableau-ultimate-chart-masterclass-63-tableau-charts/) | | **Power BI** | [Full course](https://www.youtube.com/playlist?list=PLNcg_FV9n7qZge4KDGqGtqgiuVuhVZWzu) | | | | **Databricks** | [Full course](https://www.youtube.com/playlist?list=PLNcg_FV9n7qZWchr-GE5iPPBmOjiffK6O) | | | Materials on my website: [SQL](https://www.datawithbaraa.com/wiki/sql) · [Python](https://www.datawithbaraa.com/wiki/python) · [Tableau](https://www.datawithbaraa.com/wiki/tableau) · [Power BI](https://www.datawithbaraa.com/wiki/power-bi) ### The SQL projects | Project | YouTube | Materials | Udemy | |:--|:--|:--|:--| | **Data Warehouse** | [Watch](https://youtu.be/9GVqKuTVANE) | this repository | [Building a Modern Data Warehouse](https://www.udemy.com/course/building-a-modern-data-warehouse-data-engineering-bootcamp/) | | **Exploratory Data Analysis** | [Watch](https://youtu.be/6cJ5Ji8zSDg) | [Repository](https://github.com/DataWithBaraa/sql-data-analytics-project) | [SQL for Exploratory Data Analysis](https://www.udemy.com/course/sql-for-exploratory-data-analysis-eda-real-world-project/) | | **Advanced Data Analytics** | [Watch](https://youtu.be/2jGhQpbzHes) | same repository | | More on YouTube: [Data projects](https://www.youtube.com/playlist?list=PLNcg_FV9n7qZ4Ym8ZriYT6WF8TaC2e_R7) · [Data careers](https://www.youtube.com/playlist?list=PLNcg_FV9n7qah95jp-aPtysu7kFCbg7hd) ## 🤝 Connect [](https://www.linkedin.com/in/baraa-khatib-salkini/) [](https://discord.gg/gsVJbMxKcA) [](https://www.instagram.com/datawithbaraa/) [](https://www.tiktok.com/@datawithbaraa) [](https://www.blog.datawithbaraa.com) [](https://www.notion.com/@datawithbaraa) ## 🛡️ License [MIT](LICENSE). Use it, change it, share it, with attribution. ## 🌟 About me Hi, I'm **Baraa Khatib Salkini**. I spent years in enterprise data engineering and built one of the largest lakehouses at Mercedes-Benz. Today I teach data full-time at **Data With Baraa**: visually, step by step, from zero to hero.