You're likely to be getting the shock BECAUSE your pipes are earthed. Wearing man made fibres or silk can build up a static charge. However, you'd be more likely to get the shock when you touch the tap.
My hot water is usually provided by my gas central heating, but I have a back-up immersion heater that cuts in if the pilot light blows out. I can always tell whether the water has been heated by gas or electricity because I get a tingling sensation when I put my hand under the tap of electrically heated water. The only explanation I can come up with is that the hot electric element removes more of the air from the water than the cooler indirect water pipe from the boiler. Is your water heated by electricity (if that's not too personal a question)?