Added reconnecting if the sql connection wans't found