[major] postgres migration, take 2