Sub query cannot have which clause defined for it
having clause
where clause
order by clause
group by clause