Two things, one modern, one buddhist related.
Modern sex work is mostly (but not all!) modern slavery. For example, the sex workers in Japan are often foreigners who were tricked into coming, and once in Japan, they can’t quit and don’t get paid (or at least don’t get paid what the corresponding free sex worker would get, say in the US). Slavery is bad, working as a slaver-pimp is bad, patronizing slave sex workers is bad. No one disagrees about this until they hear how much resources it takes to stomp out slavery, or that the likely solution involves decriminalizing sex work. After that though, everyone is strongly in favor of status quo and blowing hot air.
In the place where there is the legal framework for legal sex work, the situation is better, such as the porn business in LA or the strip club up the road. In modern times, with the appearance of VD tests and barrier contraceptives, we have the technology for safe prostitution, but 100 years ago, prostitution was a public health disaster.
Okay, now for a Buddhist angle. I can’t for a moment believe that the Buddha meant that right livelihood meant doing only prestigious & respected, well paid work, nor do I think he meant to create a world where we delegate the creation of goods and services that we will continue to consume as lay buddhists to a non-Buddhist outclass. I can entirely believe that society obsessed with rank, status and face would create such a system. There is more than one Buddha. There is the Buddha who created the sangha for women, a revolutionary idea, and there is the Buddha who didn’t want to and had to be convinced. We have to choose which Buddha is ours.
The Boddhisatva path means thinking hard about what it would take to help all people get out samsara. I think the Japanese (Shin and Nichiren) were on the right path when the noted that Buddhist had to be adapted to the amount of complexity that followers would put up with (hence easy chanting instead of lessons in abstruse metaphysics). Along that line, how can a Boddhisatva help anyone if the first thing they ask is that you quit your job? Especially when you know that if they quit their job, at best, it will be taken by a non-Buddhist?!
I’ve already been accused of being twisted and twisiting Buddhism, which is fine, but I’ll repeat it here: if the job isn’t going to go away, I’d rather have a Buddhist do that job, as a Buddhist, I’d rather do that job so that other people don’t have to. Why ask them to rack up the bad-karma points so that we can enjoy their services and products without racking up our own bad-karma points?
The Buddhist bar tender would dissuade customers from buying too much, the Buddhist butcher would make sure the animals were killed instead of being tortured to death, the Buddhist soldier would not sign up for an unjust war and would not participate in atrocities. A Buddhist porn director would depict sex worth copying, a Buddhist pimp would only hire free labor and run a shop that prevented unwanted children and disease.
On the otherhand, I think there are products and services that have no legitimate use what so ever, hiring contract killers or working as one. Ditto for the sale of military weaponry to people who in practice use them mostly for suicide, illegal murder, legal (in the US) vigilantism, and the killing of animals (unethical to me, but virtuous to most people in the US) The trade in most euphorics- like methamphetamine, opiates, cocaine, etc is a trade in a product that has no safe way to use it. Ditto for the trade in humans, despite vinaya texts (rules for monks) supporting slavery (i.e. banning slaves from ordaining) and monasteries at one point being only too happy to take slaves as donations and keep them as slaves. On this issue, it is a modern moral obligation to twist the vinaya until it is moral again.