First port of call -have you thought about constipation, mum does this when she is constipated as well as having a UTI's. Are they on any meds that can cause constipation or for constipation, and do you know when they last had their bowels open?
If not then its either the disease or another problem which unless you can explain needs medical help with, just to check there is no other cause other than the dementia.