Firstly, dont use turns.
Secondly, Sell all food, goods, ore, raw material, and minerals on the market. If you have less than it says you need to sell, put in the amount it says you need. Always sell for less than the current market. Wait for it to sell.
Thirdly, disband any fleet you have.
If you calculate it all up and work out that you wouldnt have enough cash to get out of debt, then you will have to restart. If your income is enough to cover the debt, then start using turns again.