Skip to main content
Admissions guidance, study banks, and career tools — get started on Shalyam

Human Traffic of Stadium

Return the rows of days with at least 100 people that belong to a run of three or more consecutive ids that all have at least 100 people. Order by visit_date.

Table schema

Stadium(id INT PRIMARY KEY, visit_date DATE, people INT)

Sample data

id | visit_date | people
1 | 2017-01-01 | 10
2 | 2017-01-02 | 109
3 | 2017-01-03 | 150
4 | 2017-01-04 | 99
5 | 2017-01-05 | 145
6 | 2017-01-06 | 1455
7 | 2017-01-07 | 199
8 | 2017-01-09 | 188

Discussion

No discussions yet.

Rewards · v2.1

Get Exclusive Insights with Every Issue

Join Shalyam Newsletter

Stay ahead in education, research, and innovation—straight to your inbox.