Modules
Data Analyst
Data Engineer
Product Data Scientist
AI Engineer
Machine Learning Engineer
Prompt Engineer
As you just joined Uber as a Data Analyst, you need to analyze how much drivers are actually earning after Uber takes its cut.
Write an SQL query to calculate the total earnings of drivers after deducting Uber's cut from the fare. For that, you will use the rides table.
rides table:
| Column Name | Data Format |
|---|---|
| ride_id | int |
| driver_id | int |
| fare | float |
| uber_cut_percent | float |
| ride_date | date |
As you just joined Uber as a Data Analyst, you need to analyze how much drivers are actually earning after Uber takes its cut.
Write an SQL query to calculate the total earnings of drivers after deducting Uber's cut from the fare. For that, you will use the rides table.
rides table:
| Column Name | Data Format |
|---|---|
| ride_id | int |
| driver_id | int |
| fare | float |
| uber_cut_percent | float |
| ride_date | date |
| total_driver_earnings |
|---|
| 200 |
| total_driver_earnings |
|---|
| 200 |