:if its a lead flange, its a job for a plumber who can solder an new flange onto the old lead pipe. if you got the bowl off and are willing to reintall it your self, it's probally a $90 plumbing job. it involves soldering lead pipe, if your not in practice your just melt the whole thing, then you have to replace, its more of an art than anything else

or you can hack the whole thing off the stack and run pvc useing a fernell bushing to couple new pvc to old cast iron.

the local plumbing supply can also sell you a repair flange that is made to easly replace flanges although sometimes they dont work, like if your pipe is crackes