Sorry if my earlier post appeared unsympathetic. It's just that the current obsession with putting chilli in everything is a pet hate of mine - I react very badly to them, and caterers hide them in things like tomato sauces, and especially in veggie dishes, which they seem to think need to be "spiced up"
I have remembered that, many years ago, I developed cracks in the skin around my bum. Probably more to do with having extremely dry skin than constipation, which I did not suffer from (but it is always the first thing the medics ask, isn't it). Can't quite remember the medical term (anal fissures?), but the effect was as you described - extreme jagged pain on passing faeces, that took a long time to calm down. It's so long ago, I can't remember what treatment, if any, I received, but it is worth seeing your GP if it doesn't calm down soon.