LeetCode 584: Find Customer Referee
Solution Guide for LeetCode 584: Find Customer Referee

I'm Varchasv, a Data Engineer working on enterprise data integration.
Currently on a 90-problem challenge to level up my technical skills and switch to a more development-focused role.
What I'm doing:
- Solving 2 Leetcode problems daily (SQL + DSA).
- Blogging about each problem.
- Building in public.
My Goal - Land a better data engineering role by mid-2026.
Follow my journey !!
Date: January 26, 2026
Category: SQL
Time Taken: 1 minute
Difficulty: Easy
Problem Statement
Find the names of the customer that are either:
referred by any customer with
id != 2.not referred by any customer.
Link: Find Customer Referee
My Approach
Since we only need names not referred by customer 2 or with no referral, it is a very basic problem.
Solution Code
SELECT name
FROM Customer
WHERE referee_id != 2 OR referee_id IS NULL
Key Takeaway: Nothing, very easy problem.
Pattern: Filter
Mistakes I Made: None
Series: 90 Days of Data Engineering Progress: 19/90 problems completed
Tags: #DEQuest #LeetCode #SQL #DataEngineering #BuildInPublic