The pressure applied to walls of the dam will be a function of the amount of water that is over that particular point on the wall. So water pressure is very large at the bottom due to its large depth. Thats why dams are constructed thicker at their bottoms than at their tops.