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
Netflix Movie Launch Pipeline
00:00
5 left

Netflix Movie Launch Pipeline

MediumSQL · PostgreSQL

Problem

Netflix is launching a new movie: design a pipeline to measure its success. Which tables do you need and which metrics would you track? Then write SQL against a movie table and a user table.

Asked in the phone screen stage. Three SQL questions were covered in 30 minutes. For the SQL portion, use the provided movies and users tables and evaluate viewing activity during each movie's first 30 days.

Output

  1. One row per movie, including movies with no qualifying viewers.
  2. Columns: movie_id, title, unique_viewers, total_watch_minutes, avg_completion_pct, completed_viewers, and avg_rating.
  3. Sort by launch date descending, then movie_id ascending.

Schema

movies
ColumnTypeDescription
movie_idPKINTUnique movie identifier
titleVARCHAR(200)Movie title
launch_dateDATENetflix release date
users
ColumnTypeDescription
user_idPKINTUnique user viewing record identifier
movie_idINTMovie associated with the viewing record
watched_atDATEDate of viewing activity
watch_minutesINTMinutes watched
completion_pctNUMERIC(5,2)Percentage of the movie watched
ratingNUMERIC(2,1)User rating from 1 to 5
Tablesmoviesusers
Interviewer

Your question is Netflix Movie Launch Pipeline. 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.