While flying, I used to experience clogged ears along with ear pain.
The clogging of my ears would last for a few hours after the flight.
My doctor prescribed Pseudovent-400 capsules. I take them the night before, and the morning of my flight. They work great, I haven't had the problem since.
Good Luck,
Rick