Translation:He bought eggs and milk from a farmer.
Das heisst "bei einem Bauern". What the heck. We want to learn German Genitiv, correctly! :-( I post it here because there is no other option to report whats wrong, just ticking a bock, doesn't solve the problem.
This is Dativ, not Genitiv. But you are right, Bauer is a strange word (look up "N declension" if interested) and usually gets an extra -n in all cases except Nominativ. This sentence has been replaced.
Correction accepted, my bad, of course it is Dative. Not sure what made me state that it is Genitive. Well, in common speach you hear people dropping the 'n' which sounds bad to my ears. Anyway you wil get a lingot to setting this right. :-)
There is some language change going on, with the "-n" for n-declined nouns ending in a consonant being more and more dropped. It seems to be most advanced with "Bär" for example, where the "regular" variant does not sound "wrong" to many people nowadays.
I noticed that when back to Germany recently, its a bit of a shame. Some of the spoken language sounds strange now to my ears. (have been to Berlin). Thats the obviously the evolution of the language, -not always a good thing.
Language is always changing. What seems to be "good" language to you was the "bad" language of an earlier generation. What is inherently "bad" about regularizing language? Does the extra -n really carry any additional information? I don't see it.