Thanks for query
It can be due to psychological problem before marriage in some people .Regular exercise of pelvic floor
muscles and anal sphincter squeezing exercise daily for 10-15 minutes may help. If still no relief consult sex specialist.At present don`t discuss the matter with the girl ,as no girl will like marry a person with erectile dysfunction
Hope I have answered your question well to your satisfaction. Wish you speedy complete recovery at the earliest.