It is not sneeze caused your eye hurt. It is bacteria and virus indeed. Many people experience sneeze because they have suffered cold. While cold is most possible due to bacteria and virus infection. Upper respiratory tract infection, people always called it cold. This disease is usual and common, but not serious. Commonly people take some medicines will be fine in a week. So during this time, eye pain, eye irritation and eye redness also happen. Sometimes you even feel hot in eyes. It is normal. Keep good mood and take notes from a doctor, you will be recovery soon.
As we know, the nerves in the whole body are interlinked, especially among the teeth, nose and eyes. It is not normal for you to get hurt eyes when you sneeze. Your eyes may get infection because of coming invisible bacterium. You need to go to use the eye drops to moisture the eyes and get rid of the bacterium. The warm compress is also a good way for you.
At first, you need to solve such question that is a generic situation or an exception. According to wikipedia, sneeze is confined as convulsive expulsion of air from the lungs through the nose and mouth, usually resulting from foreign particles irritating the nasal mucosa. So we know that it is an spasmodic involuntary action. Our eyes are highly connected to our nerves so that it can react to any changes in our body. In some cases, even the smallest things floating in the air like dusts can cause a sneeze, so just don't worry about the occational sneeze. You are too hard sneezing to hurt your eyes by changing the pressure in your cranial cavity, which change your IOP (intraocular pressure) consequently. Blowing your nose and wash your hand, it will get better later, as do your eyes. However, if it often occurs, you need head to your opticians to see if it is a intracranial disease, or even severe pathological changes of nose.