Dataford
Interview QuestionsInterview GuidesExperiencesCoaching
New
Pricing
Get started
Dataford
Popular roles
Software EngineerData AnalystData ScientistData EngineerBusiness AnalystAI EngineerMachine Learning EngineerProduct Manager
Browse
Browse All RolesEvery role hub, from analyst to MLBrowse All CompaniesCompany-specific interview loopsAll Interview GuidesThe full guide library
Top questions by role
Software EngineerData AnalystData ScientistData EngineerBusiness AnalystAI EngineerMachine Learning EngineerProduct Manager
Top questions by skill
SQLPythonStatisticsMachine LearningA/B TestingSystem DesignGenerative AIProduct SenseMetricsBehavioral
Browse all questions →Try a mock interview
Experiences
Practice
Mock InterviewsTimed interview simulations with feedbackCoaching1:1 coaching with people at your target companiesSuccess PathYour 6-week structured planModulesCurated lessons by topicWebinarsTalks from ex-Big Tech data leadsPlaygroundA free-form scratch editor
Learn
BlogInterview strategy and career adviceTech Job Market ReportHiring trends across data and AI rolesFor UniversitiesDataford for career centersAbout DatafordWho we are and how we build
Pricing
Build my plan
SQL Funnel Drop-Off Analysis
00:00
5 left

SQL Funnel Drop-Off Analysis

HardSQL · PostgreSQL

Problem

Airbnb wants to understand where users drop out of the Airbnb Homes booking funnel in the mobile app. Write a PostgreSQL query for February 2025 that measures sequential funnel engagement.

Requirements

  1. Restrict events to February 2025 and the airbnb_app surface, joining valid users from users.
  2. Report each funnel stage in order: search, listing view, reservation request, and booking confirmation.
  3. Return distinct users reaching each stage, total events from qualified users at that stage, conversion from the previous stage, and user drop-off from the previous stage. A user qualifies for a stage only if they reached every preceding stage.
  4. Include stages with no users, preserve funnel order, and calculate conversion as a decimal rounded to three places.

Schema

users
ColumnTypeDescription
user_idPKINTUnique Airbnb user identifier
signup_dateDATEDate the user signed up
country_codeVARCHAR(2)Two-letter user country code
funnel_events
ColumnTypeDescription
event_idPKINTUnique funnel event identifier
user_idINTReferences users.user_id
event_typeVARCHAR(30)Airbnb Homes funnel action
event_timestampTIMESTAMPTimestamp when the event occurred
surfaceVARCHAR(20)Product surface generating the event
Tablesusersfunnel_events
Interviewer

Your question is SQL Funnel Drop-Off Analysis. Start with the requirements and the two tables in the Question tab.

Run and submit as often as you like. When you're ready, talk me through your approach or go straight to the code.

You need to log in / sign up to run or submit.
CodePostgreSQL
Sign up free to run your codeLog inLn 1
Run your query to see results here.