Learn Without Walls
← Back to Phase 1
Phase 1 — Data Foundations
Module 4 of 14 — Final Phase 1 Module

SQL + Sheets — Putting It Together

The complete analyst workflow from database to spreadsheet to chart. This is literally your daily job.

~20 minutes
📌 Before You Start

What you need: Have both SQLiteOnline.com and Google Sheets open in separate tabs. This module connects what you have learned in Modules 1–3.

What you’ll do: You will run a SQL query with GROUP BY (a new keyword), copy the results into Google Sheets, calculate a percentage, and build a chart. That is the complete analyst workflow from start to finish.

💡 The Concept

SQL and spreadsheets are partners. They are not competing tools — they do different things.

SQL is for querying and filtering large datasets — asking the database specific questions and getting structured results. Spreadsheets are for presenting, calculating, formatting, and sharing those results with other people.

The real-world flow every entry-level analyst uses:

Write SQL query
Run it on the database
Export as CSV
Open in Sheets
Clean & calculate
Visualize
Share

New SQL keyword today: GROUP BY

GROUP BY lets you aggregate data — grouping rows together and calculating totals, counts, or averages for each group. This is how you answer “total sales by region” or “number of orders by product.” It is one of the most used SQL features in real analyst work.

SELECT region, SUM(sales) as total_sales
FROM orders
GROUP BY region
ORDER BY total_sales DESC;

“Show me total sales for each region, sorted from highest to lowest.”

🔗 Why It Matters

This SQL → Sheets → Chart workflow is literally the daily workflow of most entry-level data analysts. You will do this every single day in a real job.

Getting comfortable with the flow — not just the individual tools — is what makes you employable. Employers do not just want someone who knows SQL OR Sheets. They want someone who can move fluidly between them to produce usable results.

🖐️ Practice
1
In SQLiteOnline.com (Demo database), run this query:
Type this in SQLiteOnline.com ↓
SELECT name, SUM(value) as total
FROM demo
GROUP BY name
ORDER BY total DESC;
This groups the demo data by name and sums the values for each group, showing the highest total first. Read the results carefully.
2
Look at the results. How many distinct names are there? What is the highest total? What is the lowest? This is descriptive analytics — you are describing what the data shows.
3
Copy the results manually into Google Sheets. In a real job you would click Export → CSV and open the file. For this exercise, type the values into a new Sheet. Create a sheet titled “SQL Results” with two columns: Name and Total.
4
Add a third column called % of Total. In the first data row of that column, write a formula: =B2/SUM($B$2:$B$10) (adjust the range for your actual data). Format that column as a percentage. This shows each name’s share of the total.
5
Highlight your Name and Total columns (not the % column). Click Insert → Chart. Google Sheets will auto-suggest a chart type. Choose Bar chart. Give it a title: “Total by Name.”
6
Stop and look at what you just built. You queried a database → brought data into a spreadsheet → calculated a derived column → built a visualization. That complete workflow is the data analyst job. You just did it.
🛑 Solid stopping point. Phase 2 starts fresh — come back when ready.
🧠 Brain Break

You connected two tools today. That is integration thinking — a genuinely high-level cognitive skill. Your brain just did a lot of work moving between contexts. That deserves a real pause.

Get some water Stand up Look out a window Take 3 slow breaths

Take at least 2 full minutes. Your brain needs it to consolidate what you just learned.

✅ You Got This

The ONE thing to remember from this module:

SQL pulls the data. Sheets shapes and shows it. Together they are your core daily toolkit.

🏁 Phase 1 Complete

You completed all 4 modules of Data Foundations. You know what data analytics is, how to write SQL queries, how to clean messy data, and how to run the complete analyst workflow. Phase 2 is Visualization — turning your data into charts and dashboards with Tableau Public.

← Module 3: Data Cleaning 📋 Course Home Phase 2: Tableau Public →