Dog diarrhea causes garbage guts, food poisoning, and stress.
Stress in dogs, be it from anxiety, or too much excitement, either good stress or bad stress, causes a change in the normal intestinal bacteria, or "normal flora" in the gut.
Diarrhea from an intestinal bacterial shift can last days or even weeks.