+---------------+---------+ | Column Name | Type | +---------------+---------+ | id | int | | recordDate | date | | temperature | int | +---------------+---------+ id is the primary key for this table. This table contains information about the temperature in a certain day.
Write an SQL query to find all dates’ id with higher temperature compared to its previous dates (yesterday).
Return the result table in any order.
The query result format is in the following example:
Result table: +----+ | id | +----+ | 2 | | 4 | +----+ In 2015-01-02, temperature was higher than the previous day (10 -> 25). In 2015-01-04, temperature was higher than the previous day (30 -> 20).
# Write your MySQL query statement below SELECT t1.id FROM Weather AS t1, Weather AS t2 WHERE t1.recordDate = date_add(t2.recordDate, interval1day) AND t1.Temperature > t2.Temperature;