Consumer Lending Analyst Path · Mission 14 of 30Medium

Pricing exception detector (rate vs benchmark)

Multi-table JOIN with a threshold-comparison filter and a derived basis-point column

The Brief

Jennifer WhitmanMortgage Sales Directorconsumer-lending

Pricing-exception desk wants the weekly anomaly list. Surface every funded origination whose `interest_rate` exceeds the product's `default_apr` benchmark by more than 75bp. Six columns: `origination_id`, `product_code`, `funded_amount`, `interest_rate`, `default_apr`, `rate_premium_bp` (the premium expressed in basis points, integer). Sort by rate_premium_bp descending, then origination_id ascending for tie-break.

You'll practice

Multi-table JOINThreshold compare

Tables & columns available

lending_originationsfact17 columns
ColumnTypeKey
origination_idINTPK
app_idINTFK → lending_applications
account_idINTFK → retail_accounts
funded_dateTEXT
funded_amountREAL
term_monthsINT
interest_rateREAL
rate_typeTEXT
arm_reset_dateTEXT
fico_at_origINT
dti_at_origREAL
ltv_at_origREAL
property_valueREAL
lo_nameTEXT
channelTEXT
current_statusTEXT
closed_dateTEXT
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_productsdim6 columns
ColumnTypeKey
product_idINTPK
product_codeTEXT
product_nameTEXT
categoryTEXT
subcategoryTEXT
default_aprREAL

Hints (3)

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

Hint 1

Three-table reach: originations → applications → products. Two JOINs. The benchmark APR lives on `retail_products`; you need it alongside each origination to compute the premium.

Hint 2

"More than 75bp above benchmark" is a unit-conversion problem. Basis points are 1/100th of a percentage point — translate the bp threshold into a decimal and add it to the benchmark column. Strict `>` not `>=`; the briefing says "more than," which excludes exactly-75bp loans.

Hint 3

The premium column re-expresses the same delta in basis points: multiply the rate gap by 10000 and ROUND to an integer for a clean column type. Six projected columns, two-key sort (premium desc, id asc).