Pleading for new borrowing power to keep the District government solvent this summer, a somber Mayor Marion Barry yesterday described a cash shortage so acute that the city's unpaid electric bill has reached $4.7 million and Pepco threatened "to cut the lights off."

"We need cash," Barry said, urging a House District subcommittee to approve a measure to allow the city to issue $184 million in bonds to pay bills incurred in previous years that are now overdue.

"This is not play money we're talking about, this is cash," Barry said. "There will soon come a day when the nation's capital will be unable to pay its bills. We are using this year's cash to pay last year's debts and that string is going to run out."

Barry was testifying in support of a bill that would permit the city to sell bonds to pay of part of its $388 million cumulative deficit. Barry and his top money managers have said repeatedly that they need the money before the end of this fiscal year, Sept. 30 to stave off insolvency.

Responding to criticism that the proposed bond issue was an expensive or impractical solution, the mayor responded that all other proposals are "pie in the sky, wishful thinking, fantasizing" because they are either fiscally or politically unworkable.

Barry and his aides told the panel chaired by Rep. Ronald V. Dellums (D-Calif.) that the city would find some way to keep functioning if the bond funds are not made available, but only at a high cost in services and efficiency. They have rebuffed all suggestions that payless paydays would ensue, but Barry cited the electric-bill dispute as an indication of how dire the city's immediate cash need is.

A spokesman for Pepco confirmed that the utility had been pressing for payment of overdue bills, but denied that Pepco had threatened to cut off the city's power supply. Last week, the spokesman said, the District agreed to pay within 45 days bills of $1.6 million incurred from June to December 1980, and to pay by the end of September another $3.1 million owed for the years 1973 to 1976.

There is no money for that payment in this year's budget; it represents a good example of the kind of leftover bills that the Barry administration wants to pay off with money to be raised through a bond issue.

The District, unlike other cities, has never borrowed in the commercial bond markets; it has always borrowed from the U.S. Treasury. The 1973 home rule act anticipated that the city would borrow on the bond markets in the future, but it did not authorize the issuance of bonds to repay operating deficits from the past. Congressional approval is required for this one-time-only method of satisfying old debts.

Member of the subcommittee expressed support for the bond proposal, which is the keystone of Barry's overall financial rescue plan for the city. But they and witnesses from the financial community warned of major obstacles to be overcome before the bonds can actually be sold. Rep. Stewart McKinney (R-Conn.) said the bill would face "rough sledding" in Congress because the city has assets that could be converted into cash -- especially the vacant land for the Mount Vernon square campus of the University of the District of Columbia. McKinney said it would never be built, and the site could be sold for at least $50 million.

Freda Ackerman, director of the municipal bond department of Moody's Investor's Service, which evaluates the credit-worthiness of bond issuers, said analysts of the city's credit would raise questions about unfunded pension liability -- more than $2 billion -- and would insist that the chronically unbalanced budget "be balanced without the use of tricks or mirrors."