Connects /location route to database