Let’s say that you are an independent consultant, hawking your services as a computer programmer. The people who hire you don’t understand anything about computers; the only way they know you’re qualified to work for them is that you have a reputation for using computers to solve lots of other people’s problems.
So one day, a very rich and powerful man approaches you and says he wants to hire you. You hear him describe what he wants you to do, and after thinking over the problem for a while, you decide that you can’t do it; indeed, you’re not sure anyone can. But the man insists, and it’s clear that if you even try to fulfill his assignment, he’ll pay you very, very, very well.
If you’re an ethical consultant, and you still want to try for this man’s business, you say, “I can’t do the thing that you’re asking, but tell me more. Why do you want me to write this program? What problem are you trying to solve? If you’ll let me deviate from the specific assignment that you’re giving me here, I might find another way to solve that problem.”
If you’re an unethical consultant, you’ll just take the job and the money, continuing your patter about how you may not be able to do the work, making sure that your payment doesn’t depend on success. Who knows, maybe you’ll luck out and find a way to do the job. If not, you have excuses for failure at the ready.
What does all of this have to do with the story of Balaam? Replace “computers” with “sorcery” in the above paragraph.
From the Moabites’ statements in Numbers 22:2–4, it’s clear that Balak and his ministers (unlike, say, the Amalekites) saw themselves as acting defensively; he wanted Balaam to curse the Israelites as a means to an end. Furthermore, since Moab and Midian were not part of Canaan, Balak could have easily reached an accommodation with the Israelites that would have spared both sides from war. Balaam, with his pipeline to God, was in a position to know this. If Balak was simply concerned that Moab would suffer the fate of the Amorites, Balaam could have blessed Moab that as long as they let the Israelites pass safely, they would not be attacked. If Balak was concerned that the herds passing through would ruin Moabite pasture land (this is the opinion of the Akeidat Yitzchak, cited here), Balaam could have blessed the pastures.
But if he had investigated any of these alternatives, Balaam would have had to explicitly turn down a lucrative and ego-inflating assignment—cursing a nation that had achieved one outstanding military victory after another—and convince his client to pay him for a more modest task. An ethical sorcerer would have done just that, but Balaam was not such a man.
PS: After he failed to curse the Israelites, Balaam came up with the idea of using Moabite women to seduce them (25:1–9, 31:16). My wife points out that he could have proposed this to Balak from the start. Of course, if he had told Balak up front that something other than sorcery was Balak’s best hope for victory, it wouldn’t have done much for Balaam’s reputation as a professional sorcerer.