So you’ve trained your dog to go outdoors to relieve him-herself. But when you come home after a long day or someone comes to visit, your dog is so happy and excited or even stressed that s/he loses control and piddles.
Your dog hasn’t forgotten the house training rules, this is a behavioral problem. But there are ways to help control this behavior.
The first step will take time, but you can teach your dog to sit calmly when you come home before petting. Provide a special place, perhaps with a mat, for your dog to go to when visitors come to the door. Be consistent and use the same place each time. Ask visitors to be calm also so as not to excite the dog.
An alternative is to let the dog greet visitors outdoors so that if s/he has an accident, it won’t happen in the house.
Frequent walks and outdoor activities help keep the dog calm. S/he will be too tired to become over-excited.
Most dogs don’t enjoy being petted on top of the head. Think about how you would feel if someone tapped you on your head in greeting. When your dog is calm, you or the visitor can scratch him/her under the chin, usually a favorite petting place.
If your dog jumps on you or a visitor in greeting, turn your body sideways and wait to pet until s/he is calm.
Never punish your dog for this behavior. Punishment will only increase the behavior’s frequency and add to your dog’s stress.
Be sure to explain to visitors how they should greet your dog. Their behavior will help to train your dog and teach what is expected of him/her.
Of course before you start any training, have your dog examined by the vet to make sure the accidents aren’t caused by a medical problem.
On a personal note: I adopted a dog, my Cookie, who was badly abused. She was kicked so hard that she required 2 surgeries to mend the hip area. As a result of her injuries, she had difficulty controlling her bladder. In spite of being examined and tested extensively by several vets, they couldn’t discover why it was happening. She’s on medication, but it remains a sometimes problem. And she often piddles in excitement when guests, particularly boys and men (her abuser was male) come to the house. Because her problem is partly physical, I ask guests to greet her in the garden before bringing her indoors and it does help.