// flattening the inner plans of the demux operator.
// This is based on the fact that if a plan has a demux
// operator, then it's the only operator in the plan.
List<PhysicalPlan> pls = ((PODemux)root).getPlans();
for (PhysicalPlan pl : pls) {
demux.addPlan(pl, keyPos);
plCount++;
}
demux.addIsKeyWrappedList(((PODemux)root).getIsKeyWrappedList());
} else {
demux.addPlan(from, mapKeyType, keyPos);