Drinking a glass of water can help with heartburn but the glass of water will help with the heartburn much better if you add a tablespoon of baking soda to a half glass of water and stir it up.
If you're pregnant or have high blood pressure though be careful as the baking soda and water can cause water retention and cause high blood pressure.