Resources / Data
Free to readDataโฑ 4 min read

Excel for analyst roles: 20 formulas + pivot tables

XLOOKUP, SUMIFS, IF, TEXT, pivot tables and the mini-project that proves you can use them.

How to use this guide

Analyst and MIS interviews test Excel hands-on. Every formula below uses one sales table, shows the formula and the result it gives, and ends with practice questions and a pivot-table walkthrough.

1. The table we use

A DateB CityC ProductD UnitsE Price
201-06-2024PuneTea1020
301-06-2024HyderabadCoffee540
402-06-2024PuneCoffee840
503-06-2024ChennaiTea1220
603-06-2024PuneTea620

2. The 20 formulas

๐Ÿ“– Lookup functions (VLOOKUP / XLOOKUP)

Definition: Lookup functions search for a value in one range and return a corresponding value from another range.

How it works: VLOOKUP(value, table, col_index, FALSE) searches the first column of a table and returns the value from a given column (exact match with FALSE). XLOOKUP(value, lookup_range, return_range, if_not_found) can look in any direction, defaults to exact match and handles missing values.

Example: Find a city's revenue: =XLOOKUP("Chennai", B2:B6, F2:F6) โ†’ 240.

๐Ÿง’ In simple words

#FormulaResultUse
1=D2*E2200revenue for one row (copy down to F)
2=SUM(F2:F6)1,080total revenue
3=AVERAGE(D2:D6)8.2average units
4=COUNTIF(B2:B6,"Pune")3rows from Pune
5=SUMIF(B2:B6,"Pune",F2:F6)640Pune revenue
6=SUMIFS(F2:F6,B2:B6,"Pune",C2:C6,"Tea")320Pune tea revenue
7=AVERAGEIF(C2:C6,"Tea",D2:D6)9.33average tea units
8=MAX(F2:F6)320biggest sale
9=IF(F2>=300,"High","Normal")Normallabel rows
10=XLOOKUP("Chennai",B2:B6,F2:F6)240find a value
11=VLOOKUP("Chennai",B2:F6,5,FALSE)240older lookup
12=INDEX(F2:F6,MATCH("Chennai",B2:B6,0))240flexible lookup
13=IFERROR(XLOOKUP("Delhi",B2:B6,F2:F6),"Not found")Not foundhide errors
14=TEXT(A2,"mmm yyyy")Jun 2024format dates
15=UPPER(C2) / =TRIM(B2)TEAclean text
16=LEFT(B3,3)Hydpart of text
17=CONCAT(B2," - ",C2)Pune - Teajoin text
18=UNIQUE(B2:B6)Pune, Hyderabad, Chennaidistinct list
19=SORT(F2:F6,,-1)320, 240, 200, 200, 120โ€ฆsort
20=COUNTA(B2:B6)5non-empty cells

Revenue column F (Units ร— Price): 200, 200, 320, 240, 120.

โš ๏ธ Forgetting $ when copying

=D2*$H$1 keeps H1 fixed (e.g. a GST rate) while D2 moves as you copy down.

3. Pivot table in 5 steps

๐Ÿ“– Pivot table

Definition: A pivot table is an interactive summary table that groups, aggregates and reorganises large data sets by dragging fields into rows, columns, values and filters.

How it works: It computes sums, counts, averages or percentages per group without formulas, and updates when the source data is refreshed. Power BI and SQL GROUP BY are the same idea.

Example: Revenue by city (rows) and product (columns).

๐Ÿง’ In simple words

  1. Click any cell in the table โ†’ Insert โ†’ PivotTable.
  2. Drag City to Rows.
  3. Drag Revenue to Values (Sum).
  4. Drag Product to Columns.
  5. Right-click a number โ†’ Show Values As โ†’ % of Grand Total.
โ–ถ Output
Sum of Revenue | Coffee | Tea | Total
Chennai        |      0 | 240 |   240
Hyderabad      |    200 |   0 |   200
Pune           |    320 | 320 |   640
Total          |    520 | 560 |  1080

4. Practice (answers hidden)

  1. What is the total revenue (F2:F6)?
Show answer

200 + 200 + 320 + 240 + 120 = 1,080.

  1. Revenue from Coffee only?
Show answer

=SUMIF(C2:C6,"Coffee",F2:F6) โ†’ 200 + 320 = 520.

  1. Pune tea revenue?
Show answer

=SUMIFS(F2:F6,B2:B6,"Pune",C2:C6,"Tea") โ†’ 200 + 120 = 320.

5. Your 7-day Excel plan

๐Ÿ—“ 7 days
DayDo
1Formulas 1โ€“9 on a sample sheet
2Lookups 10โ€“13
3Text & date 14โ€“20
4Pivot tables + charts
5Data cleaning (duplicates, text to columns)
6Build a one-page sales dashboard
7Timed test: 10 tasks in 30 minutes

Further references

๐Ÿ”ฅJoin the free 30-Day Placement ChallengeOne resource and one task a day โ€” from resume to offer.