Prepare the pasta in boiling salted water according to the instructions on the packet. Drain, quench and drain well. In the meantime, dice the ham. Grate cheese. Whisk eggs, 100 g cream and milk.
Season vigorously with salt, pepper and nutmeg. Mix pasta, peas and ham. Pour into a greased casserole dish, pour egg milk over it, sprinkle with cheese and bake in a preheated oven (electric cooker: 200 °C/ convection oven: 175 °C/ gas: level 3) for approx. 50 minutes.
In the meantime peel and finely grate the onion. Melt the fat in a saucepan, add the onion and fry briefly. Sprinkle with flour and sweat. Add tomato paste, stir in, briefly sweat on and, while stirring, deglaze with stock and 100 g whipped cream.
Bring to the boil, season with salt, pepper, sugar and ketchup. Remove the casserole from the oven and garnish with marjoram. Add the sauce.