There's a director-level IT manager where I work which has made my personal job a hassle for years.
There's a follow-on business process to our main process, which was a terrible mess. I wrote a program in a year and a half which vastly simplified the process. The director is mad, because his team of 10 contractors has been unable to write a successful version for 4 years now. (Hundreds of people use my software every day. There are still no production programs using his.) I even told his team's manager how to fix what's broken about their program, and they wouldn't listen. (And then the director fired that manager.)
He wants to own the process because it's important. He needs it to line his nest. So he finally got moves made to put a sympathetic middle manager in place to force me (and my direct boss) to hand over the program to his team to maintain. As they say, if you can't code it, take it over and act like you wrote it. (And charge internal groups $1000/user/year for the privilege of using it.)
Now my job involves improving another follow-on process that's also horribly broken, even worse than the first. And I just found out at lunch today that the director MADE HIS BONES, fifteen years ago, by IMPLEMENTING the horrible process that makes all these other follow-on processes both necessary and nightmarish.
<Queue the Obama WTF GIF>
So my new quote is: "Never attribute to incompetence what can be explained as ruthlessness driven by an inferiority complex."
I'm tired now, so I won't go into how I saw this behavior distort correct outcomes and delay business improvement for personal gain, a long time ago, at another Fortune 250.
It did teach me a lot of lessons though. Never work for the company, always work for yourself. Accumulate power to make decisions, thinking that writing some kickass code is going get you somewhere is misguided.
A lot of the time this is because of the Peter Principle.[1] There are ways to combat it, though. A friend a Google explained to me that to get around this there, before being promoted you have to take on the responsibilities of the position you are looking to advance to for a few (or six?) months. Once you've proven that you can do the job passably well, they'll consider you for the promotion.
The idea is that you prevent advancing someone from an engineering role to a managerial role only to find you've lost a good engineer and gained a crappy manager, which is a double blow (ignoring for this example that engineering and managerial tracks are separate at Google AFAIK, and managers actually get paid a bit less at the same level).
I can imagine some downsides right now, such as employee burnout (since there's going to be some extra responsibilities as you attempt to do your old job and a new one at the same time), and the fact that this time perior, while somewhat long, may still not be nearly long enough to accurately gauge how a person will react in many common scenarios in the new position.
Eventually it will go to your head and you'll be viewed as a brash, arrogant, out-of-touch upper manager who throws their weight and ego around without appreciation for the repercussions of their horrendous misinformed decisions.
You either die a hero or live to see yourself become the problem.
I am not sure what can be done about incompetent people being promoted to position of power where they make horrendous misinformed decisions. Often its too late before the magnitude of their fuckups is visible, usually these people move on to different orgs with their pumped up resumes while lower level people scramble to undo the damage.