Generally, in a dry cell, cell potential is maintained by a continuous movement of ions which get completely used up after a period of time, and hence, cell potential is not maintained and the dry cell stops working. But, this does not happen in case of a mercury cell because it does not involve the movement of ions.
The reactions inside a mercury cell are as follows:
Anode:
Zn(Hg) + 2OH−(aq)→ZnO(s) + H2O(l) + 2e−
Cathode:
HgO(s) + H2O(l) + 2e−→Hg(l) + 2OH−(aq)
Overall reaction for the cell:
Zn(Hg) + HgO(s)→ZnO(s) + Hg(l)
The above overall reaction contains no ions whose concentration can change over time.
So, the cell potential remains constant throughout the mercury cell life.