Add sodium hydroxide solution drop by drop, then in excess. Calcium nitrate gives a white precipitate of calcium hydroxide that does not dissolve in excess:
Ca(NO3)2+2NaOH→Ca(OH)2↓+2NaNO3
Zinc nitrate gives a white gelatinous precipitate of zinc hydroxide that dissolves in excess, giving a colourless solution of sodium zincate:
Ammonium hydroxide also works: calcium nitrate gives no precipitate, while zinc nitrate gives a white precipitate that dissolves in excess.
Step 2 — (ii) Ammonium sulphate and sodium sulphate: warm with NaOH.
Warm each crystal sample with sodium hydroxide solution. An ammonium salt gives ammonia gas, which has a sharp, pungent smell and turns moist red litmus paper blue:
(NH4)2SO4+2NaOHΔNa2SO4+2H2O+2NH3↑
Sodium sulphate gives no gas, because there is no reaction.
Add silver nitrate solution to each. Magnesium chloride gives a curdy white precipitate of silver chloride:
MgCl2+2AgNO3→2AgCl↓+Mg(NO3)2
Magnesium nitrate gives no precipitate, because all nitrates are soluble.
Watch out: In (iii) both salts contain magnesium, so a cation test (NaOH) gives the same result for both; you must test the anion.
Therefore, (i) NaOH: white precipitate that stays (calcium nitrate) or dissolves in excess (zinc nitrate); (ii) warm with NaOH: ammonia that turns moist red litmus blue (ammonium sulphate) or no gas (sodium sulphate); (iii) AgNO₃: curdy white precipitate (magnesium chloride) or none (magnesium nitrate).