expected = migratePlan(plan);
assertTrue(expected.isEqual(newLogicalPlan));
// with 2 foreach after join
lpt = new LogicalPlanTester(pc);
lpt.buildPlan("a = load 'd.txt' as (id, v1, v2, v3);");
lpt.buildPlan("b = load 'c.txt' as (id, v4, v5, v6);");
lpt.buildPlan("c = join a by id, b by id;");
lpt.buildPlan("d = foreach c generate a::id, v5, v3, v4;");
plan = lpt.buildPlan("store d into 'empty';");
newLogicalPlan = migratePlan(plan);