Search ⌘K
Databricks
Databricks

Interview Core Track · Medium · 25 min

1. Identifying Power Users for Databricks

As a Databricks data analyst, one of the most important tasks is identifying our power users. These are users who frequently use Databricks' tools and servic...

Interview Core Track
Medium
25 min
joins
aggregation
filtering

Company labels are directional practice context, not official interview guidance.

Timer 00:00
Back to practice

Objective

Practice joins through a Databricks-tagged business scenario.

Approach

Use this track to improve speed, edge-case handling, and accuracy under timed conditions.

Company context

Company labels are directional practice context, not official interview guidance.

Prereq: query basics
Prereq: filtering

As a Databricks data analyst, one of the most important tasks is identifying our power users. These are users who frequently use Databricks' tools and services, indicating a high level of engagement. These power users often bring in substantial revenue for the company, making them crucial to identify. For this problem, assume you have been given access to two tables: 'users', containing basic user information, and 'transactions', tracking all their actions in past month. All users who made transactions with a total amount of at least 50000 in past month are considered as power user. **Write a SQL query to find out the information of power users from the 'users' table. Display the user's id, name, and the total amount they spent in past month.** The structure of 'users' and 'transactions' table is given as below: users Example Input: user_id user_name zip_code email ---------------------------------------------------------- 1001 John Doe 37027 johndoe@example.com 1002 Mary Johnson 37201 maryj@example.com 1003 James Smith 37211 jamessmith@example.com 1004 Patricia Brown 37076 pbrown@example.com 1005 Robert Davis 37013 rdavis@example.com transactions Example Input: transaction_id user_id amount date --------------------------------------------- 6001 1001 20000 2022-07-01 6002 1002 10000 2022-07-02 6003 1001 35000 2022-07-05 6004 1002 30000 2022-07-09 6005 1003 25000 2022-07-10

Pro question
This is a Pro question

Upgrade to Pro to unlock this prompt, the SQL workspace, and all 254 problems.

Upgrade to Pro — unlock all 254 problems
Editor
SQL workspace

Run queries against the protected question data, then submit once the result shape looks right.

Sign in to run SQL

Create a free account or sign in before running queries against protected question data.