If I may quote the great Max Brooks:
At close range against human attackers, this weapon reigns supreme. Against the living dead, this is not entirely true. A good twekve-gauge shotgun can literally blow a zombie's head off. However, the longer the range, the greater the pellet dispersal pattern, and the lesser chance of skull entry. A solid slug would have the same effect as a rifle, even at greater range (provided the barrel is long enough), but in that case, why not just use a rifle? What shotguns do possess is stopping power. The scattering shot acts as a solid wall, whereas a rifle bullet might pass clean throught or miss the target alltogether. If you are cornered, or on the run, and need time to escape, a good shotgun blast can send several zombies sprawling. The downside of a shotgun is that the large, twelve-gauge shells are bulky and therefore burdensome when traveling and leave less room for other equipment. This must be considered if a long journey is required.
tl;dr: Shotgun bad.