Support the project! The site exists thanks to the community. If the help covers the expenses - the platform remains free.Support →
SQL code copied to buffer
Task 67:

Data Quality Analysis

Analyze the yellow_tripdata table to identify and quantify various data quality issues. Your output should include the following columns:
- total_rows: Total number of rows in the dataset
- missing_pickup_count: Count of rows with missing tpep_pickup_datetime
- missing_dropoff_count: Count of rows with missing tpep_dropoff_datetime
- invalid_distance_count: Count of rows with invalid trip_distance
- invalid_amount_count: Count of rows with invalid total_amount
- invalid_passenger_count: Count of rows with invalid passenger_count
- invalid_time_count: Count of rows with invalid time data
- problematic_row_count: Count of rows with any quality issues
- clean_row_percentage: Percentage of rows without quality issues, rounded to two decimal places

Ensure the result is sorted by total_rows in descending order.

Use DuckDB syntax to write your answer. Descriptions of tables are provided in the right pane.

Write your request in the field below and click the "Check it!" button.
Get hint
Copy code Clear editor

Hi! Could we please enable some services and cookies to improve your experience and our website?

Privacy & Cookie Policy.