Creative Fabrica interview question

I believe the most important question on the code assignment was an easy SQL task which you could resolve by SELECTing and JOINing tables