Some work on the importOldDatabase script