hi,thanks for query.First of all it is important to know the reason for this.In most of the cases the reason very trivial and can be tackled easily.Please understand that some times perfomance anxiety
is most common cause for this.Too much of excitement,some haste can complicate things further.Try different positions,use some creama available in makert which decreases sensitivity of glans
and helps in prolonging erection,try pelvic floor
exercise which can surely help,try start and stop technique.For medicines and other advise please get in touch with your doctor.
wishing you good health.