Heat the oven to 350°F. Butter an 8x8-inch or 11x7-inch baking dish (about 2 quarts).
In a large bowl, whisk the cornmeal, flour, sugar, baking powder and salt.
Add the drained corn, creamed corn, sour cream, eggs and melted butter. Stir until no dry flour is left. Fold in the cheddar if using.
Pour the batter into the dish and spread it level.
Bake for 50 to 60 minutes, until golden on top, the center no longer jiggles and a knife in the middle comes out without wet batter (160°F in the center).
Let the casserole rest for 10 to 15 minutes before serving.