Cornerstone OnDemand Interview Question

query and relations between 2 tables