I have my waterer sitting on an upside-down flower pot and they do the same thing-dig the sand out around it and tip it over-then they start growling and complaining because their water is tipped over-they look at me like it's my fault!
I hang my waterer from a chain about five inches off the ground or so (about chest height for the birds). It keeps the birds from knocking it over or making it messy when they scratch around it. They don't seem to mind the fact that it sways slightly in the breeze. I also hang the feeder, but a touch higher, to discourage them from hopping into the open hopper and eating out of there, instead of eating at the tray like they should.
You can get hanging waterers for very cheap, and use an old dog tieout chain or a length of sturdy steel chain from the hardware store with a carabiner on the end. Voila! No more dirt in the trough, or spilled water.
they know that water on the ground can drive worms, bugs and all kinds of goodies out of the dirt and its easier to dig in. My water pans sit on scrap plywood or other lumber. Mine really go crazy when i move those boards every now and then.
mine dig in any wet spot and flop down. i keep the waterers up on bricks, concrete blocks, or cross ties to limit them knocking them over. if i forget to turn off water hose, i come home to a mud crater where it leaks.