The $4.5 million that D.C. Mayor Marion Barry added to the public school budget last week, at a time when the city is shaking the municipal piggy bank for every last dime, came from a simple fiscal maneuver worthy of an accountant.

The mayor placated parents without raising taxes going into an election year by making a technical change in the buget -- allocating funds only for current debts on city loans, not those that will come due in a year or two. That is the way the city has done business in the past, although it had earlier decided to change its accounting methods and set aside money for the future debts as well.

It was that simple -- a one-time-only transaction on paper that in the stroke of a pen made school officials and parents happy and helped alter a perception that Barry was thwarting the school system's efforts to obtain adequate funding.

It looked like the kind of financial ploy that is common in big cities: beleaguered mayor manipulates the books to "find" money he has to have. Prudent mayors all try to keep chunks of cash hidden here and there, often disguished in other budget accounts, so they can bring it out when union pressure or political realities require it.

In the words of a District Building official who is experienced in municipal finance, Barry "took out some of that unassigned revenue that every mayor has in his pocket. This is the kind of place where you hide the money you know you are going to have to have."

Since it was the third time in a month that the mayor had come up with extra money for the coming school year -- he added $1.1 million out of unspecified tax-revenue increases and $2.4 million through a property-rental exchange with the Department of Human Services -- it reinforced the impression that the mayor has more room to maneuver than he has let on.

Absolutely not so, said budget director Gladys Mack. The source the mayor tapped this week for the extra school funds, she said, was available on a one-time basis only, was made available only recently and will not be available to the next group or issue where additional spending might be desirable.

"There are no contingency funds in that budget," she said. "The mayor will not be able to go to the debt-service line again," she said, referring to the line in the budget where debt service funds are allocated.

Debt service, the repayment of loans and interest, is a major component of the city's annual budget. About 10 percent of the city's revenues are committed to debt service each year. Last fall, when Barry unveiled his proposed budget for the 1982 fiscal year, he included $166.7 million, a sharp increase over the $133.7 million in the 1981 budget.

Part of the increase was attributed to increased borrowing for construction and part to higher interest rates charged by the city's only source of loans, the U.S. Treasury. But according to Mack, $14.5 million of the increase was attributable to a change in the way the city kept its books.

On the advice of outside auditors, Mack changed the method of calculating the debt-service budget from the "cash system" to the "accrual system." That meant putting into the budget money to repay loans even before the payments were due. Normally there is a two-year lead time before repayment of principal and interest must begin, but in the accrual method of accounting, obligations must be recorded and covered as soon as they are incurred -- not when the payments are actually made -- and therefore the 1982 budget had to include funds to make loan repayments not actually due to the Treasury until 1983 or 1984.

That was in keeping with the revision of the city's entire budgetary process to put all spending, both current operating funds and capital funds, on the accrual system, which is regarded by professional accountants as the appropriate way to keep municipal books.

City Council member Betty Ann Kane (D-At Large), who has made this a major issue, objected. She said there was no reason to accelerate repayments of capital debt when the U.S. Treasury was not demanding it and she argued that a financially difficult year, such as 1982 promises to be, was not the right time to make such a costly change. Accounting principles, she argued, should not take precedence over the reality of the city's cash problems.

Her view partially prevailed when the council reviewed the budget last fall. The council took $10 million out of the debt-service accrual and transferred it to employe pay raises.

That still left $4.5 million for "partial accrual," according to Mack. That was the money Barry transferred to the school budget.

His action scrapped the accrual method of accounting in the city's capital budget, but Mack said careful study of accounting principles and techniques used in other cities had convinced the mayor and his aides that sound bookkeeping practice does not require accrual in the debt-service account.

She rejected suggestions by Kane, D.C. auditor Otis Troupe and other critics that the debt-service budget was deliberately inflated to give the mayor a cushion if he needed extra money for some other purpose, as he did this week. Kane's persistent proding on the issue, Mack said, "has taught us a lot, but the mayor has not had this ace in the hole all the time. A month ago, the accrual issue was still not resolved."