In the largest bowl you have, whisk together half-and-half, eggs, sugar, salt and pepper. Tear up bread into small pieces. Soak bread in half-and-half mixture. Meanwhile, melt butter in large skillet. Sweat onions and celery until soft, about 10 minutes, then stir in flour and cook until pasty, gradually whisk in chicken stock. Cook until thickened. Add corn and cook until corn is heated through. Toss corn mixture together with the soaked bread. Pour into greased 13 by 9-inch pan. Bake for 45 minutes.