Your body has to bring the cold water up to its own temperature, thereby burning calories. Therefore the answer to your question has certain conditions: if you value calories over being cooled down, then yes, you should drink warm water, but if you value being cooled down over calories, then you should drink cold water.
Even if you want to be cooled down, however, you should still avoid very cold drinks if you're exercising, as they can give you a stomach ache and even make you vomit. (YMMV.)
If you simply want to know if your body burns calories warming up the water, the answer is yes. [emphasis mine]
Also, avoid very cold drinks, because they can cause stomach cramps.