Dataford
Interview QuestionsInterview GuidesExperiencesCoaching
New
Pricing
Get started
Dataford
Popular roles
Software EngineerData AnalystData ScientistData EngineerBusiness AnalystAI EngineerMachine Learning EngineerProduct Manager
Browse
Browse All RolesEvery role hub, from analyst to MLBrowse All CompaniesCompany-specific interview loopsAll Interview GuidesThe full guide library
Top questions by role
Software EngineerData AnalystData ScientistData EngineerBusiness AnalystAI EngineerMachine Learning EngineerProduct Manager
Top questions by skill
SQLPythonStatisticsMachine LearningA/B TestingSystem DesignGenerative AIProduct SenseMetricsBehavioral
Browse all questions →Try a mock interview
Experiences
Practice
Mock InterviewsTimed interview simulations with feedbackCoaching1:1 coaching with people at your target companiesSuccess PathYour 6-week structured planModulesCurated lessons by topicWebinarsTalks from ex-Big Tech data leadsPlaygroundA free-form scratch editor
Learn
BlogInterview strategy and career adviceTech Job Market ReportHiring trends across data and AI rolesFor UniversitiesDataford for career centersAbout DatafordWho we are and how we build
Pricing
Build my plan
SQL Month-over-Month Growth
00:00
5 left

SQL Month-over-Month Growth

MediumSQL · PostgreSQL

Problem

Write a SQL query to calculate month-over-month growth rates for loan applications at Rupeek. Use the supplied monthly reporting periods and loan application records. Include months with no applications and return a NULL growth rate when no prior month exists or the prior count is zero.

Output

  1. One row per reporting month
  2. Columns: month_start, application_count, and mom_growth_rate
  3. Growth should be expressed as a percentage rounded to two decimal places
  4. Sort by month_start ascending

Schema

reporting_months
ColumnTypeDescription
month_startPKDATEFirst calendar day of a reporting month
loan_applications
ColumnTypeDescription
application_idPKINTUnique loan application identifier
submitted_atTIMESTAMPTimestamp when the loan application was submitted
Tablesreporting_monthsloan_applications
Interviewer

Your question is SQL Month-over-Month Growth. Start with the requirements and the two tables in the Question tab.

Run and submit as often as you like. When you're ready, talk me through your approach or go straight to the code.

You need to log in / sign up to run or submit.
CodePostgreSQL
Sign up free to run your codeLog inLn 1
Run your query to see results here.