2 hours before
You can drink clear liquids up until tho hours before your operation.
Check with your anesthesiologist on this. After this period there is a chance that some of the liquid is left in the stomach at induction. This could aspirate into your lungs during induction in a catastrophic manner. Hence we are rather serious about what and when you can drink. I hope that this answers your question.