NEW YORK (Reuters) - U.S. President Donald Trump, three of his children and the Trump Organization on Wednesday lost their bid to block Deutsche Bank AG and Capital One Financial Corp from providing financial records to Democratic lawmakers investigating Trump’s businesses.

In a decision read from the bench after hearing arguments, U.S. District Judge Edgardo Ramos in New York said Congress has the legal authority to demand the records, clearing the way for the banks to comply with subpoenas issued to them by two U.S. House of Representatives committees last month.

The committees have agreed not to enforce the subpoenas for seven days, the judge said. It was the second time in three days that a judge had ruled against the Republican president in his fight with Democrats and Trump’s lawyers were expected to appeal both decisions.

Ramos said he would not suspend his decision pending appeal.

Some Democratic lawmakers welcomed the decision.

“So far, I think the president would be wise to come to the realization that our legitimate areas of inquiry are going to be supported by the courts,” Representative Dan Kildee, a Michigan Democrat and member of the House Ways and Means Committee, told Reuters in an interview.

Representative Brad Sherman, a Democratic member of the financial services committee, was more cautious, telling Reuters in an interview that he expected the decision would be appealed.

Asked if lawmakers should be satisfied that they will get the information they seek, Sherman said, “I’ll believe it when I see it out of the U.S. Supreme Court.”

The White House did not immediately respond to requests for comment. Deutsche Bank said it would abide by the court’s decision. Capital One did not immediately respond to a request for comment.

Trump, who is seeking re-election next year, has aggressively sought to defy congressional oversight of his administration since Democrats took control of the House in January.

Ramos said that the committees had the power to issue the subpoenas under Congress’ “broad” power to conduct investigations to further legislation. He also rejected Trump’s argument that they were barred by a federal financial privacy law, the Right to Financial Privacy Act, saying the law does not apply to congressional investigations.

Trump said last month that the administration was “fighting all the subpoenas” issued by the House, hardening his position after the release of a redacted report from Special Counsel Robert Mueller on how Russia interfered in the 2016 U.S. election to help Trump and on the president’s attempts to impede the investigation.

“We remain committed to providing appropriate information to all authorized investigations and will abide by a court order regarding such investigations,” Deutsche Bank spokeswoman Kerrie McHugh said in an emailed statement after the ruling.

Slideshow ( 7 images )

Lawyers for the Trump family members and the Trump Organization declined to comment on the decision.

Some parts of the subpoenas have been included in court filings. The subpoena on Deutsche Bank seeks extensive records of accounts, transactions and investments linked to Trump, his three oldest children, their immediate family members and several Trump Organization entities, as well as records of ties they might have to foreign entities.

Deutsche Bank has long been a principal lender for Trump’s real estate business and a 2017 disclosure form showed that Trump had at least $130 million of liabilities to the bank.

Slideshow ( 7 images )

The subpoena on Capital One seeks records related to multiple entities tied to the Trump Organization’s hotel business. In March, before issuing their subpoena, Democratic lawmakers asked Capital One for documents concerning potential conflicts of interest tied to Trump’s Washington hotel and other business interests since he became president in January 2017.

Trump, his adult children, Donald Jr., Eric and Ivanka, and the Trump Organization had sought a preliminary injunction to prevent Deutsche Bank complying with the subpoenas from the House Financial Services Committee and the House Intelligence Committee, and Capital One from complying with a subpoena from the Financial Services Committee.

In a lawsuit filed on April 29, lawyers for the Trumps argued that the subpoenas were too broad, and that Democrats are hoping they will “stumble upon something” that could be used for political attacks on the president.

Patrick Strawbridge, a lawyer for Trump, said at Wednesday’s hearing that the subpoenas were “the epitome of an inquiry into private or personal matters,” and that the House committees were reaching beyond their role as legislators.

Douglas Letter, a lawyer for the committees, said the subpoenas were part of a “very serious investigation on behalf of the American people” that could lead to legislation aimed at reducing foreign influence in U.S. politics. He denied that it was intended to target Trump personally.

“He clearly sees us as some sort of nuisance,” Letter said.

The banks are the only defendants in the case, but the House committees intervened to oppose Trump’s effort to block the subpoenas.

Representative Maxine Waters, who chairs the House Financial Services Committee, told reporters after the lawsuit was filed that Trump had “cast a gauntlet.” “We will fight him,” she said.

On Monday, a federal judge in Washington ruled against the president in a similar case, finding that Trump’s accounting firm, Mazars LLP, must comply with a congressional subpoena for Trump’s financial records.

U.S. District Judge Amit Mehta found that Congress was “not engaged in a fishing expedition” for the President’s financial records when it subpoenaed Mazars and said that documents obtained might assist Congress in passing laws and performing other core functions.

Trump called Mehta’s decision “crazy” and vowed to appeal.

On Wednesday, the House committee involved in that case, the House Oversight Committee, said in a statement it had reached an agreement with Trump’s lawyers to seek an expedited appeal.