I find that what I do is the night before - drink as much water as possible to the point that my urine is clear, and then the morning of the race drink a glass of water and then make sure I go to the toilet literally right before the race - then drink an energy drink during the race and then one after. you need to get used to how your body works