Consolidate on database upgrade