I second Christian's advice, avoid ice at any open air table/food stall. And ask for unopened bottled water (which will usually be served anyway) at such sidewalk eating places.
Feel free to ask hotels or airconditioned restaurants about ice and water, but most of them will use filtered water and ice cubes also. But always pays to ask.
In the bars, I would shy away from mixed drinks for the same reason, the purity of ice in the drinks. Unless the bartender shows you packaged ice cubes in the coolers. Meaning, sticking to bottled beer would probably be the best bet, or draught beer, and even wine coolers if the establishment serves same.