as FlightPilot Says
If you have no degree and you lose your pilot's medical, you then have no qualifications! Go back to square 1 and start again with a new career.
If you have a degree and you lose your pilot's medical, you keep your degree, and are qualified to get a job as a graduate. But you will then be best placed for a job if your degree is from a good university, and has relevant subject material. Some aviation flying degrees have little management content, others quite a bit. Jobs in flight despatch, scheduling etc remain options.