SELECT * FROM wp_posts WHERE ID IN
(
(SELECT courses FROM wp_category WHERE CatID =401) OR
(SELECT meta_value FROM wp_postmeta WHERE post_id IN (SELECT courses FROM wp_category WHERE CatID =401) AND meta_key ='post_id' )
)
AND
ID IN (SELECT post_id FROM wp_locations_courses WHERE location_id = 1120)
I am having the problem with above query while i am using IN
with sub queries gave me the error Subquery returns more than 1 row
why it happens when i am using IN
clause