The Only Way to Fix Missing Data in SQL (2026)
In this tutorial, we dive deep into SQL LEAD and LAG functions to solve these complex problems. Ever struggled to figure out how to fill in NULLS in SQL when data is missing, or the row of data doesn't exist? In this video, we break down how to use the partition by clause and how to select the correct columns to fill in the NULL values. We go over real-world examples using stock data from AAPL. In many scenarios, as a data analyst, data engineer, or data scientist, you will have to decide how to handle null values. This video will provide you with some additional options you might not been aware of. 00:00 Intro 02:30 Business Problem - Filling in Null Values 05:40 Fixing Nulls using CASE Statement and LAG Function 07:05 How to use Partition By 08:00 How to use the Lead/Lag in a Window Functions If this helped you simplify your SQL queries, make sure to Like and Subscribe for more data engineering and analytics tutorials! #sqlfunctions #windowfunctions #sqltips #sqlinterviewquestions #sql
Download
0 formatsNo download links available.