Turning customer data into decisions that protect recurring revenue.
SaaS businesses generate revenue through subscriptions. But every month, some customers stop paying and leave. This is called churn. When churn is high, the business loses recurring revenue, and acquiring new customers to replace them is expensive.
Most SaaS companies struggle to answer three basic questions:
- Why are customers leaving?
- Which customers are most likely to leave next?
- What can be done to stop it before it happens?
Without clear answers, product, sales, and customer success teams operate on guesswork rather than data.
This project builds a complete analytics system for a fictional SaaS company using SQL and Power BI. Real-world subscription, usage, and support data was structured into a relational database, analyzed across four levels of SQL complexity, and visualized in an interactive three-page dashboard.
The system answers specific business questions at every level:
- Basic analysis answers what is happening: how many accounts exist, who churned, what plans are active.
- Intermediate analysis answers why it is happening: which plans lose more customers, which support issues take too long, how product usage varies across accounts.
- Advanced analysis shows the business impact: the revenue lost due to churn, whether slow support led to cancellations, and which features drive higher revenue.
- Expert analysis uses window functions to identify patterns over time: MRR change per account, feature engagement per customer, account lifetime, and pre-churn risk signals.
The final output is a Power BI dashboard that any non-technical team member can use to monitor the health of the business.
| Tool | Purpose |
|---|---|
| Microsoft SQL Server | Database creation, data modeling, all SQL queries |
| SQL Server Management Studio (SSMS) | Writing and executing SQL code |
| Power BI Desktop | Building the interactive dashboard |
| CSV Files | Source data (accounts, subscriptions, churn, usage, support) |
The project uses five structured tables connected through foreign key relationships.
Tables used:
- accounts - One row per customer. Contains plan tier, industry, country, signup date, and trial status.
- subscriptions - One row per subscription. Contains MRR, ARR, billing frequency, start and end dates, and churn flag.
- churn_events - Records every cancellation. Contains churn reason, refund amount, reactivation flag, and whether an upgrade or downgrade happened before leaving.
- feature_usage - Tracks how each customer uses specific product features. Contains usage count, duration, and error count.
- support_tickets - Logs every customer support interaction. Contains priority level, resolution time, satisfaction score, and escalation flag.
SQL Analysis - Four Levels of Depth
- Null value audit and data quality checks across all five tables
- Foreign key constraints to enforce data integrity
- 17 basic queries covering accounts, plans, tickets, and features
- 10 intermediate queries joining multiple tables to answer business questions
- 3 advanced queries covering revenue loss, support-to-churn correlation, and feature usage before cancellation
- 7 expert-level queries using window functions: RANK, LAG, RUNNING TOTAL, ROW_NUMBER, PERCENT_RANK
- 7 SQL Views created to structure clean data layers for Power BI
Power BI Dashboard - Three Pages
The dashboard is built on a single master view (vw_saas_master) and shows live, filterable business metrics.
This is the top-level summary page for leadership and business stakeholders. It shows:
- Total active accounts, total MRR, and total churned accounts at a glance
- Churn rate broken down by plan tier (Starter, Professional, Enterprise)
- Account distribution by country and industry
- Trial versus paid account split
- Churn trend over time, showing when cancellations peaked
This page answers the question: How healthy is the business right now?
This page is designed for finance, pricing, and growth teams. It shows:
- Total Monthly Recurring Revenue (MRR) and Annual Recurring Revenue (ARR) by plan
- Revenue contribution from monthly versus annual billing cycles
- Average MRR per plan tier, showing which plans generate more revenue per customer
- Revenue lost due to churn, broken down by reason code
- Running total of MRR accumulated over time since launch
This page answers the question: Where is the revenue coming from, and how much are we losing?
This page is designed for product managers and customer success teams. It shows:
- Feature adoption rates across the customer base
- Which features are used most and which are underused
- Average feature usage for accounts that churned versus accounts that stayed
- Error rates per feature, identifying where customers face product friction
- Feature versus revenue correlation, showing which features drive higher MRR
This page answers the question: Are customers actually using the product, and does engagement prevent churn?
| Business Question | Finding |
|---|---|
| Which plan has the highest churn rate? | Starter plan accounts churn significantly more than Professional or Enterprise |
| Does slow support cause churn? | Accounts with resolution times above 48 hours show higher churn rates |
| What is the revenue impact of churn? | The SQL query calculates exact ARR loss from every churned subscription |
| Do customers use the product before leaving? | Feature usage data shows activity drops before cancellation events |
| Which features drive revenue? | Features with high adoption correlate with higher average MRR |
| Are annual plans more valuable? | ARR analysis by billing frequency reveals which cycle generates more stable revenue |
| Which accounts are at risk? | Churn risk segmentation by plan tier, support time, and MRR flags high-risk groups |
Deliverables produced:
- A fully normalized SQL Server database with five tables and enforced relationships
- 40 plus SQL queries across four levels of complexity
- 7 reusable SQL views designed as a clean data layer for reporting
- A three-page interactive Power BI dashboard connected to the SQL views
- Business-ready insights on churn drivers, revenue health, and product engagement
saas/
├── Saas.sql # All SQL queries, views, and database setup
├── accounts.csv # Customer account data
├── subscriptions.csv # Subscription and billing data
├── churn_events.csv # Cancellation and churn reason data
├── feature_usage.csv # Product feature engagement data
├── support_tickets.csv # Customer support interaction data
├── saas.pbix # Power BI dashboard file
└── Screenshots/
├── Tables.png # Database schema and relationships
├── EXECUTIVE_OVERVIEW_D1.png # Dashboard page 1
├── REVENUE_&_PRICING_D2.png # Dashboard page 2
└── Product_Usage_D3.png # Dashboard page 3
Business Intelligence | SaaS Analytics | SQL | Data Visualization
Status: Completed



