fix database reference in migration 2