If you are trying to remove an old waste pipe, the following tip might be useful to you.
Make a pilot hole (with a 4 or 6mm drill bit) into the section of pipe you want to remove, quite near the joint. Place an old screw (why use a brand new one if you don’t need to!) into the hole and tighten with a screwdriver so that the screw is firmly held by the pipe. Now, place an old chisel or large flat screwdriver between the screw and the rubber joint and use it as a wedge. The pipe will move out slightly.
Make another pilot hole near the joint but further away from the first screw, ideally on the opposite side but space probably won’t allow it, leaving a large enough gap so that you will be able to fit your chisel or screwdriver. Secure another screw (or re-use the same one) and again, use your chisel as a wedge. You might have to repeat this action a few times before the whole pipe comes out of the rubber joint. It took me about 7 or 8 go’s before the section of pipe came out.