switch to postgres DB, some schema changes