The woman reportedly survived the first two rounds Zhao Liping fired and fled, before he chased her down in a car and shot her in the head.
Zhao, 64, was found guilty of murder, bribery and possession of firearms and explosives, a court in Taiyuan, the capital of the northern province of Shanxi, said in a statement on its website.
He was sentenced to death because of the "facts, nature, circumstances and degree of damage to society" of his crimes, it added. He will have an opportunity to appeal the sentence.
He was detained last year in Chifeng on suspicion of killing a 28-year-old woman with whom he "had an intimate relationship" because she wanted to expose his wrongdoings, Chinese media said earlier.
Many fallen Chinese officials have been found to have mistresses, and corruption investigations have often been triggered by allegations from spurned or angry women.