There he is recognized by a local sleazy toy collector and toy store owner as a valuable collector's item. Woody it seems was modeled on a popular cowboy TV marionette from the 1950s. Woody in stolen in order to complete a set for the collector. They are now a complete set and can come out of storage and make people happy. But to do that, Woody can never return to Andy.
Somebody has to lose.
Children's films often have characters choose between good and bad, but rarely between one good cause and another one. This is actually surprising since seven different people worked on the story and script. That generally is a very bad sign. The makers have recognized that Bo-Peep, the only female toy of the first film, left a lot to be desired in character complexity. Pixar's main stock and trade is, of course, computer animation.