When a piece of zinc metal is placed in a solution of mercuric chloride (HgCl2), a white layer of mercury is deposited on zinc metal to give it silvery shining look. This is because mercury is lower to zinc in reactivity series and hence, zinc can displace mercury from HgCl2.
But when zinc is placed in a solution of magnesium sulphate, there is no change. This is because magnesium is above zinc in the reactivity series and hence, zinc cannot displace magnesium from its salt solution.