fixed join waiting for subquery ends always more than 1 sec