Curated interview practice questions with answers. These are practice scenarios, not a verified list of past interview questions.
About UBS hiring for Data Analytics roles
UBS is a Swiss global financial services firm known for wealth management, investment banking, asset management and Swiss retail banking. It acquired Credit Suisse in 2023. In India it runs large business solutions and technology centres that hire software engineers, data analysts, risk and finance professionals, and operations roles supporting its global businesses.
For Data Analytics roles, this UBS practice set focuses most on Excel (7), Power BI (6), SQL (5), Data Modelling & Warehousing (4). It has 3 easy, 34 medium, 3 hard questions, so you can start easy and work up to the harder ones.
Company type
Banking & finance
Headquarters
Zurich, Switzerland
Main India offices
Pune, Mumbai, Hyderabad
UBS Data Analytics interview process
Online assessment (aptitude + coding)
Technical interview
Managerial or business round
HR round
Typical pattern based on public candidate experiences. Rounds vary by role, team and year.
Solved for UBSStart practicing
3 QUESTIONS FREESign up to unlock the full question bank and track your progress.Unlock every question and answer, then continue practising company-wise and package-wise.
✓ 3 questions free • Unlock the rest in seconds
01
What are variables (VAR) in DAX and why are they useful?
VAR stores the result of an expression inside a measure, and RETURN gives the final output. Variables make measures readable, avoid evaluating the same expression twice, and are evaluated in the filter context where they are defined, which helps avoid subtle bugs inside CALCULATE. They also make debugging easy, because you can temporarily RETURN a variable to check its value before returning the final result.
02
Your NOT IN query unexpectedly returns zero rows. Why might that happen, and how do EXISTS and IN differ?
IN checks whether a value is in a list or subquery result; EXISTS checks whether a subquery returns at least one row and stops at the first match. Results are the same in most cases, and modern optimisers often run them similarly. The big difference is NOT IN with NULLs: if the subquery returns any NULL, NOT IN returns no rows. NOT EXISTS behaves correctly, so prefer it for anti-joins.
03
What is the difference between a calculated table in DAX and a table created in Power Query?
A Power Query table is built during data refresh using M, before data enters the model, and is compressed like any imported table. A DAX calculated table is computed after load from other model tables, using functions such as CALENDAR, SUMMARIZE or DISTINCT. Prefer Power Query for shaping and cleaning source data. Use calculated tables for model-dependent needs, such as a date table from existing data or a small what-if table.
04
What is an action title and why should you use one?
An action title states the insight of a chart or slide as a sentence instead of a label. Instead of Monthly Sales by Region, write South region drove 70 percent of the decline since July. Busy executives may read only the titles, so each one should carry the message and, ideally, the so-what. The chart below then proves the title. Read only your titles in order: they should tell the whole story.
05
How do you calculate working days between two dates in Excel, excluding holidays?
-- A2 = start date, B2 = end date, Holidays = named range of holiday dates
=NETWORKDAYS(A2, B2, Holidays)
-- if the weekend is only Sunday (weekend code 11)
=NETWORKDAYS.INTL(A2, B2, 11, Holidays)
-- date that is 10 working days after A2
=WORKDAY(A2, 10, Holidays)
06
Your analysis shows that a flagship initiative championed by leadership is not working. How do you present it?
Prepare carefully and stay factual. Share the finding early with the initiative owner privately so they are not surprised in a big meeting. Lead with the question asked, the method and the evidence, acknowledge limitations and what is working, and avoid blaming anyone. Offer options, such as fixing a specific step, narrowing the scope or stopping, with estimated impact. Bad news delivered with solutions is received far better.
07
Write SQL to generate a simple date dimension for 2026.
-- PostgreSQL syntax
CREATE TABLE dim_date AS
SELECT
TO_CHAR(d, 'YYYYMMDD')::INT AS date_key,
d::DATE AS full_date,
EXTRACT(YEAR FROM d) AS year,
EXTRACT(QUARTER FROM d) AS quarter,
EXTRACT(MONTH FROM d) AS month_no,
TO_CHAR(d, 'Mon') AS month_name,
TO_CHAR(d, 'Dy') AS weekday,
EXTRACT(ISODOW FROM d) IN (6, 7) AS is_weekend
FROM GENERATE_SERIES(DATE '2026-01-01', DATE '2026-12-31', INTERVAL '1 day') AS d;
08
Write a DAX measure for cumulative sales from the start of the data to the selected date.
Cumulative Sales =
VAR maxDate = MAX('Date'[Date])
RETURN
CALCULATE(
[Total Sales],
FILTER(ALL('Date'[Date]), 'Date'[Date] <= maxDate)
)
-- for a running total that resets each year use TOTALYTD([Total Sales], 'Date'[Date])
A tool that summarises large tables by dragging fields into rows, columns, values and filters, so you can slice sales by region or month without writing formulas.
Sampling bias occurs when the sample does not represent the population, so conclusions do not generalise. Common types: selection bias, such as surveying only app users about website issues; survivorship bias, studying only customers who stayed; non-response bias, when unhappy customers skip surveys; and convenience sampling, using whoever is easiest to reach. Random sampling, stratification and weighting help reduce it.
11
The CMO asks which marketing channel should lose 20% of its budget. How do you approach it?
I would compare channels on incremental return, not last-click ROAS. Gather spend, attributed conversions under two models, customer quality such as repeat rate and margin, and any lift test or mix model results. Look at diminishing returns: the last rupee in a saturated channel is worth less than the average. Then recommend cutting where marginal return is lowest, ideally phased with a holdout to confirm the impact.
12
Write a Tableau calculated field for profit ratio and a profit category.
// Profit Ratio (aggregate first, then divide)
SUM([Profit]) / SUM([Sales])
// Profit Category
IF SUM([Profit]) < 0 THEN 'Loss'
ELSEIF [Profit Ratio] < 0.1 THEN 'Low margin'
ELSE 'Healthy'
END
// avoid AVG([Profit]/[Sales]): it averages row ratios and gives a wrong total
13
Tell me about a time you worked with a marketing team to improve a campaign using data.
Situation: a lead generation campaign had a high cost per lead and sales said leads were poor. Task: find what to change. Action: I joined ad data with CRM outcomes and found two audience segments produced most leads but almost no closed deals, while one smaller segment converted well. Result: we moved budget to that segment and changed the form questions; cost per qualified lead fell about 30% in six weeks.
14
What is columnar storage and why do analytical warehouses use it?
Columnar storage keeps all values of one column together on disk instead of storing full rows together. Analytical queries usually read a few columns across millions of rows, so the engine reads only those columns. Similar values sit side by side and compress very well, which cuts storage and scan cost. The trade-off is slower single-row inserts and updates, which is why OLTP databases stay row-based.
15
How do you remove duplicates in Excel but keep the latest record?
Sort by date (newest first), then Data → Remove Duplicates on the key column — Excel keeps the first occurrence. Or use UNIQUE / a COUNTIFS helper column.
16
What is the difference between a t-test and a z-test?
Both compare means. A z-test assumes the population standard deviation is known or the sample is large, so the normal distribution applies. A t-test estimates standard deviation from the sample and uses the t-distribution, which has heavier tails for small samples. In practice analysts mostly use t-tests: one-sample, independent two-sample (Welch's version if variances differ) or paired, for before-after measurements on the same users.
17
How does the FILTER function work in Excel? Write a formula to list all North region orders.
-- A2:D500 holds Order, Customer, Region, Amount
=FILTER(A2:D500, C2:C500="North", "No orders")
-- two conditions (AND) multiply the tests
=FILTER(A2:D500, (C2:C500="North")*(D2:D500>10000), "No orders")
-- OR conditions add the tests
=FILTER(A2:D500, (C2:C500="North")+(C2:C500="East"))
18
Your Tableau map shows a large number of unknown locations. How do you fix it?
Click the unknown indicator at the bottom right of the map and choose Edit Locations. Usually Tableau cannot match names because of spelling variants, such as 'Bengaluru' versus 'Bangalore', or an ambiguous city that needs the state and country set. Make sure fields have the correct geographic role, add a country or state field to the view, clean names in the data source, or use latitude and longitude columns.
19
What are additive, semi-additive and non-additive facts?
Additive facts, like sales amount or quantity, can be summed across every dimension. Semi-additive facts, like account balance or stock on hand, can be summed across accounts or stores but not across time; for time you take the closing or average value. Non-additive facts, like percentages, ratios or unit prices, cannot be summed at all, so you store their components (profit and revenue) and calculate the ratio at query time.
20
Write Python code to calculate the sample size per group for a conversion test with a 4% baseline and a 10% relative lift.
No. Privacy features in some mail apps pre-load email images, which fires the open tracking pixel even if the person never reads the email, so open rates get inflated. Check opens by email client to confirm. Move reporting towards clicks, click-to-send rate, conversions and unsubscribes, which reflect real behaviour, and avoid using opens alone to pick winning subject lines or to define engaged subscribers.
23
What is the difference between a clustered and a non-clustered index?
Talk to the intended users before redesigning. Find out whether they know it exists, whether it answers their real questions, whether they trust the numbers, and whether it fits their routine. Common fixes are fewer, sharper KPIs, faster loading, a scheduled email snapshot, or embedding it in a meeting that already happens. Then measure usage again. Sometimes the honest answer is that the dashboard is not needed and can be retired.
25
Write pandas code to find the top 2 products by revenue in each region.
Use Go To Special and select Constants with Numbers to highlight hard-typed values inside formula areas. Show Formulas (Ctrl+`) to scan columns for inconsistencies, and use Trace Precedents and Dependents on key totals. Inquire or Spreadsheet Compare, if available, can flag inconsistent formulas. Then fix the overwritten cells, protect formula ranges and add check totals that compare with the source data each month.
28
What do the match_mode and search_mode arguments of XLOOKUP control?
match_mode decides how a value is matched: 0 exact (default), -1 exact or next smaller, 1 exact or next larger, and 2 wildcard. search_mode decides direction: 1 searches first to last, -1 searches last to first, and 2 or -2 use binary search on sorted data. Searching last to first is a quick way to fetch the latest entry for a customer without sorting, and next-smaller matching handles tax slabs or commission bands.
WITH gaps AS (
SELECT customer_id,
order_date,
order_date - LAG(order_date) OVER (
PARTITION BY customer_id ORDER BY order_date) AS days_since_prev
FROM orders
)
SELECT customer_id,
COUNT(*) AS orders,
AVG(days_since_prev) AS avg_gap_days
FROM gaps
GROUP BY customer_id
HAVING COUNT(*) > 1;
-- order_date is DATE (PostgreSQL); use DATEDIFF in other databases
A correlated subquery refers to a column from the outer query, so it is logically evaluated once per outer row. Example: find employees earning above their department average with WHERE salary > (SELECT AVG(salary) FROM emp e2 WHERE e2.dept_id = e1.dept_id). It is readable but can be slow on large tables. The same result is often faster with a window function such as AVG(salary) OVER (PARTITION BY dept_id).
32
Write Python code to bootstrap a 95% confidence interval for the difference in revenue per user between two groups.
Extract filters decide which rows go into the extract file at all, which reduces its size and speeds every view; filtered rows are simply not available. Data source filters apply to all worksheets using that data source, for live or extract, and are useful for security or scope, such as only the India business. Both act before context filters. Normal worksheet filters only affect one sheet.
A conformed dimension is one dimension table with the same keys, attributes and meanings shared by several fact tables. For example, one date and one product dimension used by sales, returns and inventory facts. Because they conform, you can compare sales and returns by the same product category in one report without mismatched definitions. Conformed dimensions are the main way an enterprise warehouse stays consistent across departments.
Use a star schema, remove unused columns, prefer measures, reduce visuals per page, limit high-cardinality fields and use aggregations or incremental refresh.
MATCH finds the position of a value in a range and INDEX returns the item at that position, giving a flexible lookup that works left or right and survives column insertions.
Situation: our operations team assumed late deliveries were evenly spread. Task: I built a delivery performance dashboard. Action: I added a breakdown by courier partner and pin code cluster with a weekly trend, and reviewed it with the operations manager. Result: it showed one partner caused 60 percent of delays in two zones. The company shifted those zones to another partner, and on-time delivery rose from 84 to 92 percent in two months.
40
Write Python code to test whether conversion differs between control and treatment.
from statsmodels.stats.proportion import proportions_ztest, proportion_confint
conversions = [1180, 1295] # control, treatment
visitors = [30000, 30100]
z, p = proportions_ztest(conversions, visitors)
print(f'z = {z:.2f}, p = {p:.4f}')
for c, n in zip(conversions, visitors):
low, high = proportion_confint(c, n, method='wilson')
print(f'rate {c/n:.3%} 95% CI {low:.3%} to {high:.3%}')
Tips to crack the UBS Data Analytics interview
Revise DSA, Java or Python, SQL and OOP concepts, and be ready to explain your code clearly in interviews.
Learn basics of wealth management, investment banking and financial markets to show interest in the business side.
Prepare examples of attention to detail and handling pressure, since banking technology roles demand reliability and accuracy.
Keep a one-minute story ready for every project on your CV: problem, your part, tools, result.
Practise the hard questions on this page aloud; UBS interviewers usually ask follow-ups on your first answer.
Frequently asked questions
How many rounds are there in the UBS Data Analytics interview?
Candidates usually go through 4 stages: Online assessment (aptitude + coding); Technical interview; Managerial or business round; HR round. The exact rounds change with the role, team, location and your experience, so confirm the process with the recruiter.
Which topics should I prepare for the UBS Data Analytics interview?
This practice set leans on Excel (7), Power BI (6), SQL (5), Data Modelling & Warehousing (4). Revise those first, then practise explaining one or two of your own projects end to end, because most UBS interviewers ask you to walk through real work.
Are these the exact questions asked at UBS?
No. These are curated practice questions that match the skills and difficulty usually tested in banking & finance interviews like UBS's. They are not a leaked or verified list of past questions.
Where does UBS hire Data Analytics professionals in India?
UBS has large teams in Pune, Mumbai, Hyderabad. Openings and locations change often, so check the UBS careers page and filter by city and experience.