Katkat

practice a little every day, paws crossed ♡

Data Manipulation (SQL/Python) Interview Questions

Practice 9403 coding, system design and machine learning questions from 546 companies, sorted by role, topic and interview round. Every question has step-by-step hints, a code runner that supports 8 languages and an AI mentor; members also get the full solution walkthrough.

9403
Questions
546
Companies
11
Topics
8
Languages

Showing 301–330 of 446 results

  • OpenAIMediumData Scientist
    Write SQL to compute signup and retention lift

    This prompt evaluates SQL proficiency in time-windowed cohort analysis, event deduplication, date arithmetic, and per-variant aggregation for A/B experiments, categorized under Data Manipulation (SQL/Python) and targeted at an intermediate-level Data Scientist role.

    Data Manipulation (SQL/Python)Technical Screen
  • OracleMediumSoftware Engineer
    Classify Tree Nodes in SQL

    Tests the ability to write conditional logic and subqueries/joins in SQL to classify hierarchical tree nodes into 'Root', 'Inner', or 'Leaf'.

    Data Manipulation (SQL/Python)Technical ScreenSQLPostgreSQLTrees
  • OracleMediumSoftware Engineer
    Parse logs and query by time

    This question evaluates competency in parsing and structuring log lines, interpreting timestamps and time zones, handling malformed input, designing insert/query APIs, reasoning about scalability and indexing, performing time/space complexity analysis, and planning basic tests.

    Data Manipulation (SQL/Python)Onsite
  • OracleMediumSoftware Engineer
    Rank Departments by Student Count

    Tests SQL proficiency in outer joins, aggregation with null handling, and deterministic multi-column sorting.

    Data Manipulation (SQL/Python)Onsitesqlleft-joingroup-by
  • OtherMediumData Scientist
    Build SQL pivot with lookups and currency conversion

    This question evaluates proficiency in data manipulation using SQL or SQL-like Python transforms, covering point-in-time currency conversion, temporal joins for FX lookups, joins to enrich product/customer metadata, aggregation and pivot-style reporting, ranking, and data-quality checks for missing FX.

    Data Manipulation (SQL/Python)Technical Screen
  • OtherMediumAnalytics Engineer
    Continue Entry Numbers for a Daily Incremental Batch

    Continue per-context entry numbering for a daily batch using stored maximums, ordered row numbers, and correct new-context handling.

    Data Manipulation (SQL/Python)Technical Screen
  • OtherMediumAnalytics Engineer
    Number Entries Within Each Conversation

    Assign one-based entry numbers per conversation using timestamp and identifier ordering in a PostgreSQL window-function query.

    Data Manipulation (SQL/Python)Technical Screen
  • OtherMediumData Scientist
    Solve window-function SQL without joins

    This question evaluates proficiency with SQL window functions, including running and cumulative sums, LAG/forward-fill event logic, ranking functions (RANK/DENSE_RANK/ROW_NUMBER), tie-breaking strategies, and temporal date arithmetic for payments and subscription events.

    Data Manipulation (SQL/Python)Technical Screen
  • OtherMediumData Scientist
    Write SQL to analyze response accuracy and speed

    This question evaluates proficiency with SQL-based data manipulation and analytical querying on relational assessment data, including aggregation, grouping, joins, windowed ranking, and use of PostgreSQL statistical functions to analyze accuracy and response-time metrics.

    Data Manipulation (SQL/Python)Online Assessment
  • OthersEasyData Scientist
    Compute per-coin quarterly amounts and totals

    This question evaluates competence in SQL data manipulation—specifically time-based conditional aggregation, grouping, joins, and handling entities with no activity—to compute per-coin quarterly sums and year-to-date totals.

    Data Manipulation (SQL/Python)Online Assessment
  • Otter.AiMediumData Engineer
    Find Every Project with the Most Employees

    Build a PostgreSQL aggregation that returns every project tied for the largest employee count. This compact exercise checks grouping, maximum selection, tie preservation, empty-input behavior, and careful use of primary-key guarantees.

    Data Manipulation (SQL/Python)Technical Screen
  • Otter.AiMediumData Engineer
    Find the Highest-Paid Employee in Each Department

    Work through a tie-aware PostgreSQL problem that finds every highest-paid employee in each department. It assesses relational reasoning, correct joins, duplicate-name handling, and precise output semantics without assuming a single winner.

    Data Manipulation (SQL/Python)Technical Screen
  • PayPalMediumData Scientist
    Clean and Summarize User Purchase Data Efficiently

    This question evaluates proficiency in data cleaning, aggregation, and time-series manipulation within the Data Manipulation (SQL/Python) domain, focusing on filtering by group counts and calculating inter-event timing metrics.

    Data Manipulation (SQL/Python)Onsite
  • PayPalMediumData Scientist
    Compare WHERE vs HAVING with aggregates

    Compare WHERE vs HAVING with aggregates evaluates SQL or pandas logic, joins, grouping, window functions, null handling, edge cases, and validation in a realistic interview setting. A strong answer states assumptions, handles edge cases, explains trade-offs, and shows how to validate the result clearly.

    Data Manipulation (SQL/Python)Onsite
  • PayPalMediumData Scientist
    Explain Window Functions and Joins in SQL and Python

    This question evaluates proficiency in SQL and Python data manipulation, covering window functions, join semantics (INNER, LEFT, RIGHT, FULL, CROSS), ranking functions, group and string aggregation, type casting, and building row-wise accumulations in Python, and it falls under the Data Manipulation (SQL/Python) category.

    Data Manipulation (SQL/Python)Onsite
  • PayPalMediumData Scientist
    Identify Session with Maximum Overlapping Sessions Count

    This question evaluates temporal interval reasoning, set-based querying and aggregation skills, focusing on identifying and counting overlapping time intervals using SQL or equivalent Python data-manipulation tools.

    Data Manipulation (SQL/Python)Onsite
  • PayPalMediumData Scientist
    Identify Users with Specific Page Visit Sequence

    This question evaluates event-sequence detection and temporal ordering skills in SQL, focusing on concepts such as windowing, adjacent-row reasoning, and session-scoped grouping to identify ordered page visits.

    Data Manipulation (SQL/Python)Onsite
  • PayPalMediumData Scientist
    Write SQL to flag Venmo ATO

    This question evaluates a candidate's ability to construct complex SQL to detect account-takeover (ATO) signals in a payments platform, assessing skills in event-time windowing, deduplication, joins across user/login/transaction tables, and categorical flagging of new devices or IPs.

    Data Manipulation (SQL/Python)Technical Screen
  • PayPalEasyData Scientist
    Write SQL using HAVING and window functions

    This question tests the ability to filter aggregated data using the HAVING clause and compute relative metrics using window functions to identify high-frequency transaction patterns.

    Data Manipulation (SQL/Python)Technical ScreenSQLWindow FunctionsAggregations
  • PayPalMediumData Scientist
    Write conditional aggregates with CASE WHEN

    Write conditional aggregates with CASE WHEN evaluates SQL or pandas logic, joins, grouping, window functions, null handling, edge cases, and validation in a realistic interview setting. A strong answer states assumptions, handles edge cases, explains trade-offs, and shows how to validate the result clearly.

    Data Manipulation (SQL/Python)Onsite
  • PayPalMediumData Scientist
    Write conditional aggregation SQL queries

    This question evaluates proficiency with conditional aggregation in SQL, including the use of SUM(CASE WHEN ...) versus filtering with WHERE and the implications of placing aggregation filters in HAVING for grouped queries, within the Data Manipulation (SQL/Python) domain.

    Data Manipulation (SQL/Python)Onsite
  • PinterestMediumData Scientist
    Analyze Global Engagement and Impressions with SQL Queries

    This question evaluates proficiency in SQL-based data manipulation and analytical querying, covering aggregation, grouping, ranking, and the correlation of impressions with user engagement and feature usage metrics.

    Data Manipulation (SQL/Python)Onsite
  • PinterestMediumData Scientist
    Calculate the Percentage of Highly Active Users by Country

    Calculate highly active users by country over seven calendar days using distinct active dates and same-day surface diversity, with percentage output.

    Data Manipulation (SQL/Python)Technical Screen
  • PinterestMediumData Scientist
    Clean and Aggregate Transactions for Finance Dashboard

    This question evaluates data cleaning and transformation competencies including pandas-based vectorized operations, categorical mapping and feature flagging, as well as aggregation and summarization of transactional data in the data manipulation (SQL/Python) domain.

    Data Manipulation (SQL/Python)Onsite
  • PinterestMediumData Scientist
    Compute CTR by format for new US users

    This question evaluates a candidate's competency in SQL data manipulation and aggregation, covering joins, date-based filtering for user cohorts, deduplication, conditional summing, null-safe arithmetic, rounding, and ordering to compute a business metric (CTR).

    Data Manipulation (SQL/Python)Technical Screen
  • PinterestEasyData Analyst
    Compute percent of first-cancel users who never return

    This question evaluates a candidate's competency in data manipulation and temporal analysis using SQL/Python, focusing on computing user-level metrics and correctly ordering time-based events.

    Data Manipulation (SQL/Python)Technical Screen
  • PinterestMediumData Analyst
    Compute percent of first-cancelled users who never rebook

    This question evaluates proficiency in SQL data manipulation—specifically use of window functions, CTEs, deduplication by earliest timestamp, temporal comparisons, and cohort-level aggregation—within the Data Manipulation (SQL/Python) domain for a Data Analyst role in health‑tech product analytics.

    Data Manipulation (SQL/Python)Technical Screen
  • PinterestMediumData Scientist
    Find the Share of Power Listeners per Region from Play Events

    Write a PostgreSQL query that, for a trailing 7-day window, classifies listeners per region as active or 'power' users based on how many distinct days they listened and whether they used at least three different playback devices on any single one of those days, then reports the power-user share per region.

    Data Manipulation (SQL/Python)Technical Screensqlwindow-functionsaggregation
  • PinterestMediumData Scientist
    Find top video category by average time

    This question evaluates a candidate's ability to perform data manipulation and aggregation in Python (pandas), covering skills such as filtering, handling nulls and nonpositive values, mapping categorical IDs to names, rounding numerical results, and applying tie-breaking rules.

    Data Manipulation (SQL/Python)Technical Screen
  • PinterestMediumData Scientist
    Implement Binary Search for Policy Violation Logs

    This question evaluates understanding of algorithmic search and data manipulation skills, specifically applying binary search over date-ordered logs and composing efficient queries using SQL and Python.

    Data Manipulation (SQL/Python)Onsite