Now, if you are referring to a "short sale" as Alan was referring to - that's another ball of wax. Don't kid yourself into thinking you'll be paying off your loan short and going straight into another mortgage. Your credit will take a hit and you will need to wait to rebuild it.
If you're selling for $10,000 less than you OWE, then you either have to come to the table with that $10,000, or make arrangements with the lender to accept a short-sale, wherein they take the loss.
They'll only do that under certain circumstances (most of them involve some sort of financial hardship on your part), so if you can afford to pay the shortfall, that's probably the route you'll need to go.