Are you nervous or have anxiety about something?
I know when I get nervous about something I feel like gagging when trying to eat.
It might be something to do with your stomach when nervous as it is for me when I'm nervous my stomach starts to feel like it has butterflies or something else in it.
When I stop being nervous or worried about something then my stomach loosens up and I can eat fine.
Of course it could be something else for you entirely that you might want to see a doctor about.