The regresh database script from Douglas