The way you ask this question is too broad.
Which part of your sewer pipe needs replacing? Exposed pipe in your basement or crawlspace is too simple for you to be asking about.
If you mean the sewer pipe that connects your house to the city sewer (generally under the street) you have a big task. Depending on what part of the country you are in, this section of your sewer pipe can be anywhere between 4 feet and 20 feet deep. In either case you'll need a backhoe to dig it up.