The original ending — which, like the ending in the version that hit theaters, featured a dragon, but which did not involve Downey Jr. giving the dragon an enema — was said to lack humor and focus on a familial thread pegged to the death of Dolittle's wife.
Several sources say it was Downey who came up with the idea of the dragon colonoscopy/enema moment at the last minute.
Even when it was decided that the dragon was constipated, there was debate over logistics. One cut, according to sources, featured Dolittle removing a boulder-sized stool out of the dragon. In the end, the film showed bagpipes as the constipating culprit, with the good doctor enduring a windfall of gas.
Hollywood magic.