PTC Interview Question

Solve SQL Query, using Constraints