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
ExperiencesCoaching
New
Practice
Mock InterviewsTimed interview simulations with feedbackSuccess 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
Get started
Validating Analytics Before Leadership
00:00
5 left

Validating Analytics Before Leadership

MediumSQL · PostgreSQL

Problem

Describe your process for validating the results of an analytical project before presenting them to leadership at Biogen.

For the hands-on SQL portion, use the supplied source measurements and project results to identify agreement, discrepancies, missing records, and null values.

Output

  1. One row per metric, region, and month represented in either table
  2. Columns: period_start, region, metric_name, reported_value, source_value, absolute_difference, and validation_status
  3. Include records missing from either side and order by period_start, region, and metric_name

Schema

source_measurements
ColumnTypeDescription
event_idPKINTUnique source measurement identifier
event_dateDATEDate of the source measurement
regionVARCHAR(50)Reporting region
metric_nameVARCHAR(100)Name of the measured metric
metric_valueDECIMAL(12,2)Measurement value
validation_flagVARCHAR(20)Source record validity indicator
project_results
ColumnTypeDescription
project_result_idPKINTUnique analytical result identifier
period_startDATEFirst day of the reporting month
regionVARCHAR(50)Reporting region
metric_nameVARCHAR(100)Name of the analytical metric
reported_valueDECIMAL(12,2)Value reported by the analytical project
Tablessource_measurementsproject_results
Interviewer

Whenever you're ready, walk me through your approach or go straight to the code. The requirements and the two tables are in the Question tab.

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.