President Trump campaigned as one of the world's greatest dealmakers, but after nine months of struggling to broker agreements, lawmakers in both parties increasingly consider him an untrustworthy, chronically inconsistent and easily distracted negotiator.

As Trump prepares to visit Capitol Hill on Tuesday to unify his party ahead of a high-stakes season of votes on tax cuts and budget measures, some Republicans are openly questioning his negotiating abilities and devising strategies to keep him from changing his mind.

The president's propensity to create diversions and follow tangents has kept him from focusing on his legislative agenda and forced lawmakers who might be natural allies on key policies into the uncomfortable position of having to answer for his behavior and outbursts.

Sen. Lamar Alexander (R-Tenn.) spent weeks cooking up a health-care bill with Sen. Patty Murray (D-Wash.) — and felt he suddenly had Trump's attention and encouragement when the president called him Oct. 7.

Dinner with his wife interrupted by the call, Alexander said he sat on a curb outside a restaurant for 15 minutes talking about health care with Trump, whom he said supported reaching a bipartisan deal.

But this past week, Trump created whiplash. On Monday — just moments after Alexander and Murray released the blueprint for a short-term authorization of federal subsidies that help lower-income Americans afford coverage but that the administration had just halted — Trump said he supported the effort.

A few hours later, however, the president was decidedly cool to it.

"There was a lot of momentum building for Lamar's effort, until the president changed his mind after encouraging him twice to move ahead," Sen. Bob Corker (R-Tenn.) said. "You know, who knows where he'll be? Maybe where he is this very second?"

Corker said his fellow Tennessean has "the patience of Job" to negotiate with Trump, referring to the biblical prophet who suffers one curse after another but keeps his faith.

If the absence of any signature legislation is an indication, the dealmaking skills that propelled Trump's career in real estate and reality television have not translated well to government.

Tony Schwartz, a longtime student and now critic of Trump who co-wrote the mogul's 1987 bestseller "The Art of the Deal," said Trump's dealmaking modus operandi is, "I am relentless and I am not burdened by the concern that what I'm doing is ethical or truthful or fair."

"The expectation that you will stand by what you said you would do is higher in politics than it is in the cutthroat world of real estate," Schwartz added. "That's a brutal environment in which misdirection and bullying and making one offer and changing it later are all common practice."

Trump has blamed the absence of major accomplishments on Capitol Hill — one exception is the Senate's confirmation of Justice Neil M. Gorsuch, Trump's Supreme Court nominee — entirely on lawmakers.

"We're not getting the job done," Trump said last Monday at his Cabinet meeting. "And I'm not going to blame myself, I'll be honest. They are not getting the job done. . . . I'm not happy about it, and a lot of people aren't happy about it."

But senators said the president shares responsibility for this year's turbulence and gridlock, observing that the glacial pace of writing and passing laws, complicated by fits and starts, has been a culture shock for Trump.

"He's a guy who, you know, comes from the business world, and he's in a hurry to get things done," Senate Republican Conference Chairman John Thune (S.D.) said. "Around here, that's hard. You know, things take a while. So it's a process — and sometimes, kind of a slow and painful one."

Trump's lack of ideological roots makes him an unusual figure in Washington, where most lawmakers adhere rigidly to their party's agendas. Sen. Joe Manchin III (D-W.Va.) said Trump "feels much more comfortable working and talking in a bipartisan manner than he does trying to defend a partisan side."

Sen. Orrin G. Hatch (R-Utah), who met with Trump and lawmakers at the White House this past week, agreed. "I think the Democrats are crazy to not try and deal with him directly," he said. "Seven years ago, he was a Democrat. It doesn't take any brains to realize that he'd be open."

Indeed, Schumer and House Minority Leader Nancy Pelosi (D-Calif.) emerged from a September dinner with Trump thinking they had a deal with the president to back legislation protecting undocumented immigrants, known as "dreamers," who were brought to the United States as children.

But in October, the Trump administration released a list of hard-line principles that effectively derailed any such deal. The White House wish list included toughening immigration laws and funding construction of a wall at the U.S.-Mexico border, and officials ruled out granting a path to citizenship for the dreamers.

Trump has been traveling the country to pitch his plan for broad tax cuts, targeting in particular Manchin and other Democratic senators up for reelection in 2018 in states Trump won last year. The president boasted this past week of being able to easily pass tax legislation this fall, even though a bill has not been introduced.

"I think we're going to have the votes for taxes," Trump said Friday in an interview with the Fox Business Network. "And I will say, the fact that health care is so difficult, I think, makes the taxes easier. The Republicans want to get it done, and it's a tremendous tax cut."

But Trump has sent mixed messages about what this tax cut measure will be. In early October, Sen. Heidi Heitkamp (D-N.D.) told constituents that the emerging White House plan seemed to be the kind of bill she would support.

"I've met with the president's people four or five times now, and they've told me, no, this really is going to be a middle-class tax cut," Heitkamp said at a roundtable in Bismarck, near where Trump gave a speech in September pushing his tax cut plan.

Ten days later, however, Heitkamp told reporters at the Capitol that the administration's plan remained a mystery. "I still don't know what it is," she said.

Schumer said the key to getting things done on Capitol Hill is for the president to take a back seat.

"Our Republican colleagues are going to have to realize, if they want to get something done, they can't follow his erratic path," Schumer said. "They have to lead him, not follow him."

Of course, Trump has never considered himself a follower. Asked whether his advice would even be possible, Schumer said the Alexander-Murray health-care fix could be a model. "It's going to happen on this," he said.

One way some lawmakers are trying to influence and focus Trump is to interact frequently with him.

Graham has endured fierce fights with Trump — when they were competing for the 2016 Republican presidential nomination, Trump read aloud Graham's cellphone number at a rally and exhorted his supporters to call it — but he is embracing his role as a mediator between fellow senators and the president.

Graham has tried to iron out his differences with Trump over recent rounds of golf. They played together twice this month at Trump National Golf Club in Virginia, and after their first outing, Graham apparently tried to flatter the president by heaping praise on his swing in an interview with sportswriter Michael Bamberger, who has golfed with Trump many times .

"What impressed me about the president is that he has a nice, compact swing, and he can get it up and down from jail," Graham said. He added: "He hit the ball on the screws almost every time. He sets up behind the ball. He has an athletic swing. He goes down and gets it."

Schwartz said playing to Trump's ego, as Graham has with his golf compliments, is an effective way to manage him. His advice to those seeking to make deals with Trump: Find the most persuasive way to portray one's agenda as a personal victory for the president, and be the last person to talk to him.

"Trump is motivated by the same concern in all situations, which is to dominate and to be perceived as having won," Schwartz said. "That supersedes everything, including ideology."