Back to problems

Write SQL for theme-park revenue and visits

SQL · Capital One · Medium

An amusement park stores ticketing and admission data in five relational tables: a product catalog, raw ticket orders, pre-aggregated unit totals for the latest fiscal year, annual-pass active windows, and park visit logs. Write SQL for parts (a)–(d). Return each query and the final numeric answer on the provided sample rows. Pay attention to these edge cases: one guest may own several passes over time; in part (c), count only visits inside the matching pass window; passes…

Checking your access…