So far there have been a lot of posts pointing out that sex does indeed sell, but not so much explanation of why this would be especially true for pharmacy reps relative to other sales positions.
I would guess it’s like this: being attractive is valuable for any customer-facing position, and attractive salespeople know this and are therefore able to negotiate higher salaries. This means that the hottest salespeople will go and work for the companies which are willing to pay the highest premium for attractiveness. Logically, you’d expect this to be the case in markets where there is a large profit margin on the product.
As Voyager pointed out, doctors don’t pay out of their own pocket for the prescriptions they write, so they have no particular incentive to keep costs down. When you’re buying something with your own money, you’re more likely to look past the salesperson’s cleavage and go for the cheaper product, rather than the one which needs to be sold as a higher price because the company which produces it has to spend extra money on sales staff.
When you’re making buying decisions for someone else, you have no reason to go for the lowest price. So the optimal strategy for the pharma companies is apparently to sell at a high markup and then spend some of that extra money on hot salespeople.