@@ -3819,9 +3819,9 @@ void fix_semijoin_strategies_for_picked_join_order(JOIN *join)
3819
3819
Json_writer_array semijoin_plan (thd, " join_order" );
3820
3820
for (i= first + sjm->tables ; i <= tablenr; i++)
3821
3821
{
3822
+ Json_writer_object trace_one_table (thd);
3822
3823
if (unlikely (thd->trace_started ()))
3823
3824
{
3824
- Json_writer_object trace_one_table (thd);
3825
3825
trace_one_table.add_table_name (join->best_positions [i].table );
3826
3826
}
3827
3827
best_access_path (join, join->best_positions [i].table , rem_tables,
@@ -3858,9 +3858,9 @@ void fix_semijoin_strategies_for_picked_join_order(JOIN *join)
3858
3858
Json_writer_array semijoin_plan (thd, " join_order" );
3859
3859
for (idx= first; idx <= tablenr; idx++)
3860
3860
{
3861
+ Json_writer_object trace_one_table (thd);
3861
3862
if (unlikely (thd->trace_started ()))
3862
3863
{
3863
- Json_writer_object trace_one_table (thd);
3864
3864
trace_one_table.add_table_name (join->best_positions [idx].table );
3865
3865
}
3866
3866
if (join->best_positions [idx].use_join_buffer )
@@ -3897,9 +3897,9 @@ void fix_semijoin_strategies_for_picked_join_order(JOIN *join)
3897
3897
Json_writer_array semijoin_plan (thd, " join_order" );
3898
3898
for (idx= first; idx <= tablenr; idx++)
3899
3899
{
3900
+ Json_writer_object trace_one_table (thd);
3900
3901
if (unlikely (thd->trace_started ()))
3901
3902
{
3902
- Json_writer_object trace_one_table (thd);
3903
3903
trace_one_table.add_table_name (join->best_positions [idx].table );
3904
3904
}
3905
3905
if (join->best_positions [idx].use_join_buffer || (idx == first))
0 commit comments