added frame for join statements