Consumer Lending Analyst Path · Mission 11 of 30Medium

Approval rate by FICO band

CASE bucketing on a continuous variable + conditional ratio across a JOIN

The Brief

Marcus HollandChief Credit Officerconsumer-lending

Risk committee asked for the approval-rate cut by FICO band. Bucket the bureau score into five bands — `<620`, `620-679`, `680-739`, `740-799`, `800+` — and report approval rate per band. Four columns: `fico_band`, `approved_count`, `total_apps`, `approval_rate` (4 decimals). Sort by `fico_band` ascending. Skip apps where the customer record has a NULL FICO — the bureau pull failed for those and they don't belong in this view. Also skip walk-in applicants (`customer_id IS NULL`) — they don't have a customer record to pull FICO from.

You'll practice

CASE bucketingRatio

Tables & columns available

lending_applicationsfact18 columns
ColumnTypeKey
app_idINTPK
customer_idINTFK → retail_customers
product_idINTFK → retail_products
application_dateTEXT
requested_amountREAL
requested_termINT
loan_purposeTEXT
action_takenINT
denial_reason_1INT
aus_recommendationTEXT
rate_spreadREAL
lien_statusINT
occupancyINT
ethnicityINT
raceINT
sexINT
age_bucketTEXT
property_tractTEXTFK → lending_geography
retail_customersdim13 columns
ColumnTypeKey
customer_idINTPK
household_idTEXT
first_nameTEXT
last_nameTEXT
date_of_birthTEXT
stateTEXT
segmentTEXT
fico_currentINT
estimated_incomeREAL
kyc_riskTEXT
acquisition_channelTEXT
onboarded_dateTEXT
statusTEXT

Hints (3)

Each hint you reveal reduces the XP you can earn. Try the query first.

Hint 1

FICO is on the customer dim, not the application — JOIN through customer_id. Walk-ins (NULL customer_id) and rows with NULL FICO both belong outside the population per fair-lending convention; the briefing calls both out.

Hint 2

The bands are CASE-bucketed on `fico_current`. Build the labels so they lex-sort in ascending order — a numeric prefix on each label is the cleanest way to control sort without a helper column.

Hint 3

The approval-rate piece reuses M6's pattern exactly — conditional aggregation for the numerator, COUNT(*) for the denominator, NUMERIC cast before the divide to avoid integer truncation.