This is Urist McImdsm of Iton Datan, member of the Tomb of Heroes.

We've been attacked by (initially) 32 undead. They've since eaten chickens and badgers.

We are holed up in our fortress, which has walls on three sides with a 1 tile water moat outside of the walls, and a river on the right of the fortress. We are 22 dwarves strong, safe inside our tunnels, with ample food and drink. The drawbridge is up and secure.

We don't really have a functioning military, but I suppose we now have the time to train.

What options do I have for getting rid of these undead attackers?

I was thinking, we could build an archery platform and when they walk near, pelt them with bolts, but then, can't undead only be killed by decapitation? How should we handle this?

Our beards grow long whilst we ponder the situation.