MEDIUMVerified Real Interview• Risk & Fraud Quantitative Analyst
High-Dispute Merchant Chargeback Thresholds
Verified Source:Public Candidate Interview Report
Stripe's Risk team monitors merchants whose chargeback dispute rate exceeds regulatory caps.
Write a SQL query to identify all merchants with at least 5 processed charges whose dispute rate is strictly greater than 20.0%.
Return merchant_id, total charges (total_charges), disputed charges (disputed_charges), and the dispute percentage rounded to 2 decimals (dispute_pct).
Sort by dispute_pct descending.
Tables:
charges(charge_idINT,merchant_idINT,amountDECIMAL,is_disputedBOOLEAN)
Execution Sandbox:
Your query executes inside an isolated in-memory PostgreSQL engine (PGlite WebAssembly). You have full access to standard PostgreSQL aggregations, window functions, and CTEs.
Standard SQL (ANSI)|Ln 1, Col 1(7 lines, 123 chars)
Tab Indent⌘↵ Run Query
Ready to execute. Press Run (⌘+Enter)
Write your query and click “Run” or press ⌘+Enter to inspect output.