Democrat Gallego has conceded to Flores in the race to replace convicted former state Sen. Carlos Uresti, D-San Antonio, in a Democratic-leaning district. Flores will become the first Hispanic Republican to serve in the state Senate.

Republican Pete Flores defeated Democrat Pete Gallego on Tuesday night in the special election runoff for Senate District 19, a major upset in a Democratic-friendly seat with implications for the balance of power in the upper chamber.

With all precincts reporting, Flores beat Gallego by 6 percentage points in the race to replace convicted former state Sen. Carlos Uresti, D-San Antonio. Flores had 53 percent of the vote and Gallego 47 percent in unofficial returns.

Gallego conceded to Flores around 9 p.m., according to both campaigns.

“I owe this first to God and then to the grassroots in all of our counties in Senate District 19,” said Flores, who was backed by Texas’ highest-ranking Republicans. “Primarily this is an example of what happens when you have a united front and a grassroots effort. So now it’s time to go to work.”

Flores’ victory grows the Senate GOP majority to 21 members, an important figure as the caucus enters the November elections looking to protect its supermajority with as many as three of its seats in play. Currently, Republicans need a three-fifths majority — 19 members — to bring legislation to the floor without Democratic support.

Flores is a former Texas game warden who unsuccessfully ran against Uresti in 2016, while Gallego is a former congressman from Alpine who previously served more than two decades in the Texas House. The defeat in SD-19 is Gallego’s second tough loss in two years after he came up short in 2016 in a hard-fought bid to reclaim his old U.S. House seat.

Flores will finish Uresti’s term, which stretches into 2021. The former lawmaker resigned in June after being found guilty of 11 felonies, including fraud and money laundering, related to his involvement with FourWinds Logistics, a now-defunct oilfield services company found to have perpetrated a Ponzi scheme that defrauded investors.

The first round of the special election was July 31, when Flores beat expectations and placed first in the eight-way race after earning a raft of late endorsements from Gov. Greg Abbott, Lt. Gov. Dan Patrick and both U.S. senators. Gallego came in second, finishing atop a more crowded Democratic field that also featured San Antonio state Rep. Roland Gutierrez.

The Texas GOP kicked off the overtime round with a lawsuit to remove Gallego from the ballot, claiming he was ineligible because he did not live in the district as required by state law. The effort was eventually unsuccessful, but Flores’ high-ranking backers pressed forward, with Patrick, the Senate president, tapping his own campaign to the tune of nearly $175,000 to assist Flores.

In ads, Flores depicted Gallego as a tax-loving liberal and “career politician” desperate to return to power. Gallego countered with his long-running message that he would be a safe, reliable choice for the district in the wake of the tumultuous period that precipitated Uresti’s resignation.