Dataford
Interview QuestionsInterview GuidesExperiencesMock InterviewsPricing
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
Designing KPI Dashboard for Launch
00:00
5 left

Designing KPI Dashboard for Launch

MediumSQL · PostgreSQL

Problem

Walk me through how you would design a KPI dashboard for a new product launch.

Write a PostgreSQL query using the provided launch and event data to produce a 30-day KPI view for every launch.

Output

  1. One row per product launch with product_id, product_name, launch_date, page_views, signups, activated_users, paying_users, revenue, and signup_rate.
  2. Include launches with no qualifying events, using zero values for their metrics.
  3. Include only events from the launch date through the following 30 days, excluding events on the thirtieth day after launch.
  4. Order by launch_date ascending, then product_id ascending.

Schema

product_launches
ColumnTypeDescription
product_idPKINTUnique product launch identifier
product_nameVARCHAR(100)Product name
launch_dateDATEProduct launch date
launch_events
ColumnTypeDescription
event_idPKINTUnique event identifier
launch_idINTProduct launch associated with the event
event_dateDATEDate on which the event occurred
user_idINTUser associated with the event
event_typeVARCHAR(50)Event category such as page_view, signup, activation, or purchase
revenueNUMERIC(12,2)Revenue attributed to a purchase event
Tablesproduct_launcheslaunch_events
Interviewer

Your question is Designing KPI Dashboard for Launch. 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.