Corrected the separate DB connection