Leetcode SQL

584. Find Customer Referee

Given a table customer holding customers information and the referee.

Write a query to return the list of customers NOT referred by the person with id ‘2’.

For the sample data above, the result is:

Solution:

Link

--

--

My homepage to record my thought processes for solving SQL and Algorithm questions

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store