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

Ranking hot weather

You are working on a global climate report and need to determine the hottest temperatures for various weather stations. Hawaii is next on your list to analyze and rank the hottest months on record.

Rank the HI weather station data by t_monthly_max. Rank 1 should appear first and have the highest temperature. Temperatures that are the same should have the same rank, but no ranking levels should be skipped.

You will need to join temperatures_monthly and temperature_stations.

Bu egzersiz

Time Series Analysis in PostgreSQL

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

Egzersiz talimatları

  • Rank t_monthly_max for the HI weather station by joining the two tables; rank 1 should have the highest temperature.

Uygulamalı interaktif egzersiz

Bu örnek kodu tamamlayarak bu egzersizi bitirin.

-- Rank the highest temperatures in Hawaii
SELECT
	ts.state,
	year_month,
	t_monthly_max,
    ___ OVER (___) AS rank
___ AS tm
___ AS ts 
	USING(station_id)
___
ORDER BY rank;
Kodu Düzenle ve Çalıştır