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
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
Approach to Unstructured Data
00:00
5 left

Approach to Unstructured Data

MediumSQL · PostgreSQL

Problem

Describe your approach when you are given a large, unstructured dataset and asked to begin your analysis for Energy Aspects’ data-driven insights.

Use the provided tables to demonstrate the initial analysis by producing a trustworthy monthly summary from the raw observations.

Output

  1. One row per commodity, region, and observation month.
  2. Columns: commodity_name, region, observation_month, average_price, observation_count, and source_count.
  3. Include only active commodities and sources, valid positive USD-per-barrel observations, and non-empty regions. Sort by commodity, region, and month ascending.

Schema

market_observations
ColumnTypeDescription
observation_idPKINTUnique observation identifier
commodity_idINTReferenced commodity
source_idINTReferenced data source
observed_atDATEDate of the market observation
regionVARCHAR(100)Market region
price_textVARCHAR(50)Raw price value as text
unitVARCHAR(30)Unit associated with the price
quality_flagVARCHAR(30)Raw validation status
commodities
ColumnTypeDescription
commodity_idPKINTUnique commodity identifier
commodity_nameVARCHAR(100)Commodity name
market_groupVARCHAR(50)Broad commodity market group
is_activeBOOLEANWhether the commodity is currently active
data_sources
ColumnTypeDescription
source_idPKINTUnique source identifier
source_nameVARCHAR(100)Data source name
source_typeVARCHAR(50)Type of source
is_activeBOOLEANWhether the source is currently active
Tablesmarket_observationscommoditiesdata_sources
Interviewer

Your question is Approach to Unstructured Data. Start with the requirements and the three 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.