Free Big SQL Energy Beginner Course: Lesson 0 & 1, Intro & select * from
It's HEREEEE! All written material, datasets, YouTube vids, and info is below!
Got BDE?⚡️
Hi BDEs! Welcome to Lessons 0 & 1 of the free Big SQL Energy Beginner Course⚡️ Today we’re getting setup and learning the super basics of writing our first SQL query!
Return to Big SQL Energy Beginner homepage here to access the other lessons:
If you’re new here:
💁🏽♀️ Who Am I?
I’m Jess Ramos, the founder of Big Data Energy and the creator of the BEST SQL course and community: Big SQL Energy⚡️. Check me out on socials: 🔗LinkedIn, 🔗Instagram, 🔗YouTube, and 🔗TikTok. And of course subscribe to my 🔗newsletter here for all my upcoming lessons and updates— all for free!
⚡️ What is Big SQL Energy?
🔗Big SQL Energy Intermediate is an intermediate SQL course designed to solve real-world business problems hands-on using realistic data and a modern tech stack. You’ll walk away with 2 SQL portfolio projects, portfolio building guidance, access to the Big Data Energy Discord community, and lots of confidence for you upcoming coding interviews! You also get access to all monthly events including masterclasses, office hours, and guest speakers. This course is all of the most important things I’ve learned on the job as a Senior Data Analyst in tech who grew from a $72K salary to over a $150K salary. And now I’m sharing it with YOU! It’s more than just another course— it’s a challenging program designed to upskill your SQL to the intermediate level, get ready to ace your live coding interviews, and build connections in the data community through the Discord and events.
Lesson 0: Intro & Getting Started
Before you start, you’ll need access to any IDE (integrated development environment) for SQL of your choosing. I highly recommend using a 🔗Hex data science notebook because it’s easy to get started with and stored in the cloud— so no headaches to download and set up. However, you can alternatively use DBeaver, MySQL Workbench, SSMS, or any others if you’d prefer. Just import the dataset used in the lesson, and you’re ready to go! Remember, if you get stuck or experience errors, ChatGPT and Gemini are great resources to learn about syntax and help you debug. Alright, let’s get started!
🔗 Join Hex Data Science Notebooks: https://app.hex.tech/signup/big-data-energy
🔗 Datasets (Orders & Customers): https://github.com/jessramosdata/big-sql-energy-beginner
Lesson 1: select, from, & *
If you’ve never worked with a database before, don’t worry, we’re starting at step 1 in SQL today. You know how spreadsheets have rows and columns? Well tables in a database are similar. Tables in a database have many rows that each represent a single transaction and entity. And for ever row, there are values in each of the columns that provide more information about that row.
As data analysts, we’re always having to pull data from the database, but knowing what to pull and how to pull it can be a challenge. In the real world, tables can have millions of rows and hundreds of columns, so it can be difficult to narrow down which datapoints and how much data you need for your analysis. Also sometimes we have to summarize data by aggregating it or reshape it to transform it into something new. We’ll get into that a little later! But first, let’s pull our first data from the database.
Here we’re using a CSV (similar to an Excel sheet) for simplicity to learn the basics, but my 🔗intermediate course uses a data warehouse in Snowflake which is more realistic for the real world.
Every SQL query you write to pull data will use SELECT and FROM, which are SQL clauses. Note that SQL is not case sensitive, so you can write it in all caps, all lowercase, or even ✨LiKe ThIs✨ (which I don’t recommend LOL!). This below will pull or select all columns and rows from the X table:
select
*
from
orders
This is the simplest query you can write. It says “give me everything in the X table”. Star (aka *) means “everything” or “all the columns”. If you want to just select a single column, you can type the column name like this:
select
order_id
from
orders
Or you can select multiple columns by separating them with commas:
select order_id, customer_id, product_name from orders
Although it doesn’t affect the syntax, it’s best practice to use this spacing format when writing queries to keep things organized. This will be especially important as we write longer and more advanced queries:
select
order_id,
customer_id,
product_name
from
orders
I use trailing commas like this, but many people prefer leading commas as shown below:
select
order_id
,customer_id
,product_name
from
orders
Leading commas vs. trailing are a big (fun) debate online, but at the end of the day, it doesn’t matter which you use. Most people use trailing in the real world.
Congrats! 🎉 You’ve just written you’re first few queries! The sky is the limit— I’ll see you in the next lesson.
If you’ve enjoyed the free BEGINNER Big SQL Energy course, grab my intermediate course. There are no deadlines or timelines for this course— you start and take as long as you want. It will take your beginner skills to the next level and get you ready to ace your interviews.
DM me or email me at courses@bdeanalytics.com if you have questions on the intermediate course!
Return to Big SQL Energy Beginner homepage here to access the other lessons:
Happy New Year!!
I am excited about learning SQL in this course and the intermediate course.
HNY