IBM Interview Question

Sql related problem which i couldn't solve