Methods of welding flanges to pipe