displaying content using entityfieldquery
I think this is the right way because it works for me. Error was in below line.

$query-&gt;fieldCondition('field_product_sub_cat', 'tid', $all_children[$i],'=');


Correct way to compare with array is:

 $query-&gt;fieldCondition('field_product_sub_cat', 'tid', array("$your_array_variable"));