Barney runs for sheriff when Andy seems lined up for another job. Andy's job falls through and he becomes a write-in candidate for re-election.