Revive database migration logic;