Blue Yonder Interview Question

queries based on grouping and having clauses