Fix a issue when more than two yDimensions and there are equal values in the diffrent ydimension levels.