Feeling lightheaded is commonly due to less blood flowing the brain at that time.
Feeling lightheaded when bending is usually due to a condition known as orthostatic hypertension. When you bend over, or more specifically when you straighten up after bending over, less blood flows to the brain - this causes lightheadedness or dizziness.
A serious cause of orthostatic hypertension is pulmonary hypertension - high pressure in the arteries from the heart to the lungs. Minor causes are dehydration, anemia or ear problems.
This is not due to stomach problems.
Please consult a doctor - you need a thorough investigation for an accurate diagnosis.