For me, I did this a lot during my college days. My college drinking wasn't the type of drinking that would help you on race day, that is for sure!
I read a few years ago, that it is a good to practice your drinking during the training runs. Essentially, you will be training yourself to run and drink. One stressful part of a long distance race is the water stops. The traffic is intense and the last thing you want to do during a race is experiment.
Race day experiments are not advised. I DO recommend experimenting during your training. One other aspect to figure out is water vs. sports drink.
I can drink just about anything during the race, but some people have digestive issues. If you are worried about digestive issues and need more than just water, I would recommend mixing water and Tailwind. Whatever you do, experiment during your training. I have tried Gatorade, Powerade, and a number of other drinks. Tailwind seems to work best for me.