improved database connections