PracHub
QuestionsPremiumCoachesLearningGuidesInterview Prep

Quick Overview

This question evaluates SQL-based product analytics skills, including anomaly detection, funnel construction, joins and aggregations, and data-quality/instrumentation checks across platform and app_version.

  • Medium
  • Meta
  • Data Manipulation (SQL/Python)
  • Data Scientist

Write SQL to localize anomaly and funnel

Company: Meta

Role: Data Scientist

Category: Data Manipulation (SQL/Python)

Difficulty: Medium

Interview Round: Technical Screen

Given the schema and toy data below, write SQL to (a) validate instrumentation vs behavior change, (b) localize the 2025-09-01 Likes drop by app_version and platform, and (c) build a daily funnel. Schema: users(user_id INT, region STRING); posts(post_id INT, author_id INT, created_at DATE); feed_impressions(user_id INT, post_id INT, created_at DATE, platform STRING, app_version STRING); likes(user_id INT, post_id INT, created_at DATE, platform STRING, app_version STRING); app_sessions(user_id INT, session_id STRING, session_date DATE, platform STRING, app_version STRING); outages(date DATE, region STRING, outage_minutes INT). Sample tables (ASCII): Users user_id | region 1 | US 2 | US 3 | IN 4 | BR Posts post_id | author_id | created_at 10 | 1 | 2025-08-30 11 | 2 | 2025-08-31 12 | 3 | 2025-09-01 Feed_Impressions user_id | post_id | created_at | platform | app_version 1 | 10 | 2025-08-31 | iOS | 10.5.0 2 | 11 | 2025-08-31 | Android | 9.9.1 1 | 11 | 2025-09-01 | iOS | 10.6.0 3 | 12 | 2025-09-01 | Android | 9.9.2 4 | 12 | 2025-09-01 | Web | web Likes user_id | post_id | created_at | platform | app_version 1 | 10 | 2025-08-31 | iOS | 10.5.0 2 | 11 | 2025-08-31 | Android | 9.9.1 1 | 11 | 2025-09-01 | iOS | 10.6.0 App_Sessions user_id | session_id | session_date | platform | app_version 1 | s1 | 2025-08-31 | iOS | 10.5.0 2 | s2 | 2025-08-31 | Android | 9.9.1 1 | s3 | 2025-09-01 | iOS | 10.6.0 3 | s4 | 2025-09-01 | Android | 9.9.2 4 | s5 | 2025-09-01 | Web | web Outages date | region | outage_minutes 2025-09-01 | IN | 45 Tasks: 1) Write a query that, for 2025-08-18..2025-09-01, computes daily like-through-rate (distinct likers / distinct viewers) by platform and app_version, and flags segments with a ≥5 percentage-point drop on 2025-09-01 vs their prior 14-day mean; 2) Write a funnel query for 2025-08-31 and 2025-09-01: feed viewers → like impressions (join on impressions) → likes, with stage-to-stage conversion; 3) Write a data-quality check that compares likes per session across platforms and versions to detect logging regressions (e.g., sudden zeros on iOS 10.6.0). Explain how you’d join outages to avoid false alarms.

Quick Answer: This question evaluates SQL-based product analytics skills, including anomaly detection, funnel construction, joins and aggregations, and data-quality/instrumentation checks across platform and app_version.

Last updated: Mar 29, 2026

Loading coding console...

PracHub

Master your tech interviews with 8,500+ real questions from top companies.

Product

  • Questions
  • Learning Tracks
  • Interview Guides
  • Resources
  • Premium
  • For Universities
  • Student Access

Browse

  • By Company
  • By Role
  • By Category
  • Topic Hubs
  • SQL Questions
  • Compare Platforms
  • Discord Community

Support

  • support@prachub.com
  • (916) 541-4762

Legal

  • Privacy Policy
  • Terms of Service
  • About Us

© 2026 PracHub. All rights reserved.

Related Coding Questions

  • Compute ad impression conversion rates - Meta (medium)
  • Count unconnected posts and reactions - Meta (medium)
  • Count heavy callers in 7 days - Meta (medium)
  • Write SQL for call metrics - Meta (medium)
  • Write SQL for multi-account metrics - Meta (medium)