DISH interview question

They asked me to type SQL Query