BaşlayınÜcretsiz Başlayın

Explore with division

In exploring a new database, it can be unclear what the data means and how columns are related to each other.

What information does the unanswered_pct column in the stackoverflow table contain? Is it the percent of questions with the tag that are unanswered (unanswered ?s with tag/all ?s with tag)? Or is it something else, such as the percent of all unanswered questions on the site with the tag (unanswered ?s with tag/all unanswered ?s)?

Divide unanswered_count (unanswered ?s with tag) by question_count (all ?s with tag) to see if the value matches that of unanswered_pct to determine the answer.

Bu egzersiz

Exploratory Data Analysis in SQL

kursunun bir parçasıdır
Kursu Görüntüle

Egzersiz talimatları

  • Exclude rows where question_count is 0 to avoid a divide by zero error.
  • Limit the result to 10 rows.

Uygulamalı interaktif egzersiz

Bu örnek kodu tamamlayarak bu egzersizi bitirin.

-- Divide unanswered_count by question_count
SELECT ___/___::___ AS computed_pct, 
       -- What are you comparing the above quantity to?
       ___
  FROM stackoverflow
 -- Select rows where question_count is not 0
 WHERE ___ ___ ___
 ___ ___;
Kodu Düzenle ve Çalıştır