claimed that he had opposed the Iraq War “from the beginning”?

Trump voiced criticism of the war before many other public officials of the time, however his frequently repeated claim that he opposed the war “from the beginning” is false.

Trump voiced support multiple times, even preceding the invasion, such as in his 2000 book “The America We Deserve” and a 2002 interview with Howard Stern in which he said, “Yeah, I guess so. I wish the first time it was done correctly.”

Trump first criticized the war in 2004, about a year after it began.

During that 2004 interview with Esquire, Trump remarked,

My life is seeing everything in terms of “How would I handle that?” Look at the war in Iraq and the mess that we’re in. I would never have handled it that way. Does anybody really believe that Iraq is going to be a wonderful democracy where people are going to run down to the voting box and gently put in their ballot and the winner is happily going to step up to lead the county? C’mon. Two minutes after we leave, there’s going to be a revolution, and the meanest, toughest, smartest, most vicious guy will take over. And he’ll have weapons of mass destruction, which Saddam didn’t have.

Trump also argued the point throughout the primary and Presidential debates.

His opponent, Hillary Clinton, expressed regret for her Senate vote for the Iraq War in a 2006 interview, saying, “Obviously, if we knew then what we know now, there wouldn’t have been a vote, and I certainly wouldn’t have voted for it.”

Esquire – Donald Trump: How I’d Run the Country (Better)
CNN – Fact check: Trump falsely claims, again, to have opposed the invasion of Iraq
Snopes – Was Trump Against the Iraq War from the Beginning?
Politifact – Jeb Bush, Hillary Clinton and authorizing the war in Iraq