Eating them regularly makes the body adjust. The gassy effect goes away.
Also...soaking and or precooking beans, then draining and using them reduces the gasses