Overflow valve with flange connection