Why is GOP self-destructive?

Why do Republicans keep attacking their members? They bicker and denounce each other. That's not how you win elections. Case in point is the ill-fated 2008 ticket of Sen. John McCain and Gov. Sarah Palin. Ms. Palin and her family were ruthlessly attacked — by her own party — which contributed to Senator McCain losing his bid for the presidency. The latest example is Dr. Benjamin Carson who has expressed no desire to position himself for public office and is instead voicing strong, sensible solutions to some of the problems in this country.

When are the Republicans going to learn there must be unity within the party in order to win the election for the highest office in the country? You never see the Democrats attack each other.