Database connection finalised