This question is about my 2.5 year old niece. She was doing really well with potty training, but then had something happen like a diaper rash or some constipation problem (my sister isn't sure) that made it hurt to poop and now she freaks out and refuses to go on the potty. She does this at home and at daycare. It is so bad that she refuses to poop at all (holds it in) and is now pooping in her sleep when her body relaxes.

They took her to the doctor today and the doc said it is totally a psychological thing and to take a break from trying to potty train for awhile, but didn't give much other advice.

Have any of you dealt with something like this and what did you do to fix it? How much time would you give before resuming potty training again?