index file modified to test database connection