my @elements = split /\|/,$$prodRef[$a]; my $prodKey = join ('|', @elements[@arrofIndices]);